Spec file encoding (was: fedpkg: Failed to get repository name from Git url or pushurl)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kenneth Goldman wrote:
> > -----Original Message-----
> > From: Miro Hrončok <mhroncok@xxxxxxxxxx>
> > 
> > On 16. 02. 23 14:50, Kenneth Goldman wrote:  
> > > Could not execute mockbuild: Could not query n-v-r of hello: 'utf-8' codec  
> > can't decode byte 0x93 in position 259: invalid start byte
> > 
> > That indicates it's not actually UTF-8.  
> 
> I can only report when I cut and paste the smart quotes
> from the web page to the .spec file (Firefox -> emacs), I
> get 0x93 and 0x94 and fedpkg reports that error.

So apparently Emacs saved the file in some Microsoft encoding, probably
Windows code page 1252, but FedPKG tried to read it as UTF-8.

When I load the packaging tutorial I get UTF-8 from the web server, so
it seems that something on your computer converted the text into a
Microsoft encoding.

Programs should generally use the character encoding specified in your
locale, but FedPKG might be hardcoded to use UTF-8, perhaps justified
by the policy that Fedora spec files must be UTF-8 encoded:
https://docs.fedoraproject.org/en-US/packaging-guidelines/#_spec_file_encoding

If you're going to cooperate with the rest of us in the Fedora project,
then you'll need to handle UTF-8 in spec files. Sooner or later you'll
encounter some non-ASCII characters. You may need to tell Emacs to read
and write spec files as UTF-8, or you may need to fix your locale. Run
"locale" to check. Going by your email address, en_US.utf8 is probably
the right locale for you.

Björn Persson

Attachment: pgpXcO9F6NPvX.pgp
Description: OpenPGP digital signatur

_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Users]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]

  Powered by Linux