[OS X TeX] .sty files listed as Kind STY and Asian characters

Murray Eisenberg murrayeisenberg at gmail.com
Tue Sep 29 22:37:48 CEST 2020


OK, lsregister output includes the following. SOMETHING has changed the locale to zh_CN, hence the pair of Chinese characters for these types.

I do not see how to change that, e.g., by using System Preferences > Language & Region > Apps. If I try to add a new Customize item for TeXShop.app, it already shows “Language: System Default - English”.

--------------------------------------------------------------------------------
type id:            org.tug.mp (0x585dc)
bundle:             TeXShop (0x28d7c)
uti:                org.tug.mp
localizedDescription: "LSDefaultLocalizedValue" = "mp", "zh_CN" = "mp 文件"
flags:              active  imported  trusted (0000000000000041)
conforms to:        public.text, public.plain-text
tags:               .mp
--------------------------------------------------------------------------------
type id:            org.tug.mf (0x585e0)
bundle:             TeXShop (0x28d7c)
uti:                org.tug.mf
localizedDescription: "LSDefaultLocalizedValue" = "mf", "zh_CN" = "mf 文件"
flags:              active  imported  trusted (0000000000000041)
conforms to:        public.text, public.plain-text
tags:               .mf
--------------------------------------------------------------------------------
type id:            org.tug.sty (0x585e4)
bundle:             TeXShop (0x28d7c)
uti:                org.tug.sty
localizedDescription: "LSDefaultLocalizedValue" = "sty", "zh_CN" = "STY 文件"
flags:              active  imported  trusted (0000000000000041)
conforms to:        public.text, public.plain-text
tags:               .sty
--------------------------------------------------------------------------------
type id:            org.tug.cls (0x585e8)
bundle:             TeXShop (0x28d7c)
uti:                org.tug.cls
localizedDescription: "LSDefaultLocalizedValue" = "cls", "zh_CN" = "CLS 文件"
flags:              active  imported  trusted (0000000000000041)
conforms to:        public.text, public.plain-text
tags:               .cls
--------------------------------------------------------------------------------
type id:            org.tug.bst (0x585ec)
bundle:             TeXShop (0x28d7c)
uti:                org.tug.bst
localizedDescription: "LSDefaultLocalizedValue" = "bst", "zh_CN" = "bst 文件"
flags:              active  imported  trusted (0000000000000041)
conforms to:        public.text, public.plain-text
tags:               .bst
--------------------------------------------------------------------------------
type id:            org.tug.bib (0x585f0)
bundle:             TeXShop (0x28d7c)
uti:                org.tug.bib
localizedDescription: "LSDefaultLocalizedValue" = "bib", "zh_CN" = "TeX bib 文件"
flags:              active  imported  trusted (0000000000000041)
conforms to:        public.text, public.plain-text
tags:               .bib
--------------------------------------------------------------------------------

[Actually, _i_ prefer top-posting, to more readily see the latest on a thread without having to scroll to the bottom. Others will flame about this!]

> On 29 Sep2020, at 3:33 PM, Adam R. Maxwell <amaxwell at mac.com> wrote:
> 
> Hi Murray,
> 
> With the lsregister output, redirect it to a temp file, e.g., /path/to/lsregister -dump >/tmp/lsreg.txt
> 
> and then scan through it with a text editor and judicious use of cmd-f to find what you're looking for. Search for the offending characters and hopefully you'll find where that's defined, and what application of plugin is responsible. The Launch Services database is basically the Mac OS equivalent of Windows' Registry, with the difference being that you can't edit it directly, you can only read it with brute force, and it's more fragile.
> 
> Pardon the top-post, but icloud webmail destroys proper quoting.
> 
> Adam
> 
> On September 29, 2020 at 7:59 AM, Murray Eisenberg <murrayeisenberg at gmail.com <mailto:murrayeisenberg at gmail.com>> wrote:
> 
>> On 29 Sep2020, at 1:09 AM, Adam R. Maxwell via MacOSX-TeX <macosx-tex at email.esm.psu.edu <mailto:macosx-tex at email.esm.psu.edu>> wrote:
>>> 
>>>> On Sep 28, 2020, at 11:59 , Murray Eisenberg <murrayeisenberg at gmail.com> wrote:
>>>> 
>>>> I’m seeding that (on .cls, too, not just .sty) in any Finder window I open anywhere there is such a file. For example, in subfolders of my own Documents and in every subfolder of /usr/local/texlive/2020/texmf-dist/tex/latex that I open in Finder.
>>> 
>>> The first step is to run mdls on a .sty file in Terminal and see what it gives you for kMDItemKind and kMDItemContentType (I think those are the relevant ones).
>>> 
>>> Once you find the kMDItemContentType, you'll probably end up having to inspect the output of lsregister to see what application or plugin is defining it. I'd guess that whatever is defining it has a localization problem with the way types are defined. On Mojave the command is:
>>> 
>>> /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -dump
>>> 
>> 
>> 
>> I ran mdls on both memhfixc.sty and memoir.cls in /usr/local/texlive/2020/texmf-dist/tex/latex/memoir. Those are two from among _all_ .sty and .cls files that now show the two Japanese (?) characters in the Kind column of Finder list view. Output included:
>> 
>>                mdls memhfixc.sty
>>      kMDItemKind = "sty"
>>      kMDItemContentType = “org.tug.sty"
>> 
>>                mdls memoir.cls
>>  kMDItemKind = “cls"
>>      kMDItemContentType = "org.tug.cls"
>> 
>> I tried next "lsregister - dump”, but the output is huge, and I have no idea what to look for or do with the output. I tried piping to, e.g., “grep org.tug.sty” but get so many lines and no hint of what to do with that.
>> 
>> ---
>> Murray Eisenberg              murrayeisenberg at gmail.com <mailto:murrayeisenberg at gmail.com>
>> 503 King Farm Blvd #101        Home (240)-246-7240
>> Rockville, MD 20850-6667  Mobile (413)-427-5334

---
Murray Eisenberg			murrayeisenberg at gmail.com
503 King Farm Blvd #101	Home (240)-246-7240
Rockville, MD 20850-6667	Mobile (413)-427-5334


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/macostex-archives/attachments/20200929/3ca4fab8/attachment.html>
-------------- next part --------------
----------- Please Consult the Following Before Posting -----------
TeX FAQ: http://www.tex.ac.uk/faq
List Reminders and Etiquette: https://sites.esm.psu.edu/~gray/tex/
List Archives: http://dir.gmane.org/gmane.comp.tex.macosx
                https://email.esm.psu.edu/pipermail/macosx-tex/
TeX on Mac OS X Website: http://mactex-wiki.tug.org/
List Info: https://email.esm.psu.edu/mailman/listinfo/macosx-tex


More information about the macostex-archives mailing list.