public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: Daniel Pielmeier <daniel.pielmeier@googlemail.com>
To: gentoo-dev@lists.gentoo.org
Subject: Re: [gentoo-dev] Patch make_desktop_entry to produce entries that validate better
Date: Sun, 18 Nov 2007 02:59:23 +0100	[thread overview]
Message-ID: <473F9C7B.4060204@googlemail.com> (raw)
In-Reply-To: <473F80D5.5060004@gentoo.org>

[-- Attachment #1: Type: text/plain, Size: 972 bytes --]

Petteri Räty schrieb:
> Petteri Räty kirjoitti:
>> Any objections to the attached patch:
>>
>> betelgeuse@pena ~ $ desktop-file-validate
>> /usr/share/applications/jedit-jedit.desktop
>> /usr/share/applications/jedit-jedit.desktop: warning: key "Encoding" in
>> group "Desktop Entry" is deprecated
>> /usr/share/applications/jedit-jedit.desktop: warning: value "" for key
>> "Path" in group "Desktop Entry" does not look like an absolute path
>>
>> Regards,
>> Petteri
>>
> 
> Hmm. Wrong patch attached.

There are two other bugs (#197891, #181999) which are related to changes
regarding the freedesktop specs. One for the Encoding key depreciation
which you can see above too and one for the Icon key which should not
specify a suffix if the value does not use the full path to the icon.
These could be taken into consideration when desktop-file-utils-0.14 is
stable on all archs.

I have attached an updated patch.

Regards,

Daniel




[-- Attachment #2: make_desktop_entry.patch --]
[-- Type: text/plain, Size: 841 bytes --]

--- eutils.eclass	2007-11-18 02:06:50.000000000 +0100
+++ eutils.eclass	2007-11-18 02:32:44.000000000 +0100
@@ -741,7 +741,7 @@
 
 	local exec=${1}
 	local name=${2:-${PN}}
-	local icon=${3:-${PN}.png}
+	local icon=${3:-${PN}}
 	local type=${4}
 	local path=${5}
 
@@ -875,18 +875,18 @@
 
 	cat <<-EOF > "${desktop}"
 	[Desktop Entry]
-	Encoding=UTF-8
 	Version=1.0
 	Name=${name}
 	Type=Application
 	Comment=${DESCRIPTION}
 	Exec=${exec}
 	TryExec=${exec%% *}
-	Path=${path}
 	Icon=${icon}
 	Categories=${type};
 	EOF
 
+	[[ ${path} ]] && echo "Path=${path}" >> "${desktop}"
+
 	(
 		# wrap the env here so that the 'insinto' call
 		# doesn't corrupt the env of the caller
@@ -938,7 +938,6 @@
 
 	cat <<-EOF > "${desktop}"
 	[Desktop Entry]
-	Encoding=UTF-8
 	Name=${title}
 	Comment=This session logs you into ${title}
 	Exec=${command}

  reply	other threads:[~2007-11-18  2:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-17 22:53 [gentoo-dev] Patch make_desktop_entry to produce entries that validate better Petteri Räty
2007-11-18  0:01 ` Petteri Räty
2007-11-18  1:59   ` Daniel Pielmeier [this message]
2007-11-20 22:32     ` Chris Gianelloni

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=473F9C7B.4060204@googlemail.com \
    --to=daniel.pielmeier@googlemail.com \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox