Git Product home page Git Product logo

Comments (15)

seigneurfuo avatar seigneurfuo commented on June 11, 2024

Something like this: https://github.com/seigneurfuo/nemo-mediainfo-tab/commit/e843a313622f56d00dd9c09f90116618d4eac7dc

It takes the first file found on /usr/share/nemo-mediainfo-tab/translation.

from nemo-mediainfo-tab.

linux-man avatar linux-man commented on June 11, 2024

I committed some changes. What do you think?
You're right: translation files were not packaged by anyone, so I decided to add them to the extension.
Can you test it?

from nemo-mediainfo-tab.

seigneurfuo avatar seigneurfuo commented on June 11, 2024

I think your python script is way better than mine ! Auto locale detectection is great !

For translation files, I think putting them all in /usr/share/nemo-python/extensions is a bad idea, or maybe considering rename thoses files with the project name; something like that: nemo-mediainfo-tab-.csv.

I think it could create conflicts with any other applets if the translations files keep theres actuals names.

from nemo-mediainfo-tab.

linux-man avatar linux-man commented on June 11, 2024

The files are in /usr/share/nemo-python/extensions/nemo-mediainfo-tab/locale.
It's impossible to create a conflict with a path like this...
Since is relative to the script position, code works on systems with a different extension path.
It don't pollute /usr/share folder.
I think it's a not-bad solution.

from nemo-mediainfo-tab.

seigneurfuo avatar seigneurfuo commented on June 11, 2024

Ho ! I got wrong, I didn't understand how Debian packaging system works.
Yes in that case I dont have any modifications to add. I will test this to see if it works for me.

from nemo-mediainfo-tab.

seigneurfuo avatar seigneurfuo commented on June 11, 2024

So, it works ! To test it out, i just use the .py script and the fr.csv file. French locale is loader from the file without any problem.

from nemo-mediainfo-tab.

linux-man avatar linux-man commented on June 11, 2024

Then, v.0.3, here we go!
I'll update README.md with your name, if you don't mind.

from nemo-mediainfo-tab.

seigneurfuo avatar seigneurfuo commented on June 11, 2024

No problem !

Will you push this 0.3 update on your other flavors too (the nautilus and mate version ?)

from nemo-mediainfo-tab.

linux-man avatar linux-man commented on June 11, 2024

Done.
@yochananmarqos and @Corax26, time to update?

from nemo-mediainfo-tab.

yochananmarqos avatar yochananmarqos commented on June 11, 2024

@linux-man Updated all three.

from nemo-mediainfo-tab.

linux-man avatar linux-man commented on June 11, 2024

One issue: nemo-mediainfo-tab/locale should be copied to /usr/share/nautilus-python/extensions/.

from nemo-mediainfo-tab.

yochananmarqos avatar yochananmarqos commented on June 11, 2024

@linux-man Fixed.
Shouldn't the locale files be in /usr/share/locale? For example: /usr/share/locale/en_GB/LC_MESSAGES/nemo-mediainfo-tab.csv.

from nemo-mediainfo-tab.

linux-man avatar linux-man commented on June 11, 2024

These aren't normal locales, like the mo files you can find, and in my mind there's a difference between an application and an extension: it's like a 2nd class app who doesn't have the right to spread everywhere like an application does. Maybe it's just me...

It's almost there 😁
cp -a ${pkgname}-${pkgver}/nemo-extension/${pkgname}/locale/. ${pkgdir}/usr/share/nemo-python/extensions/nemo-mediainfo-tab/locale
or
cp -a ${pkgname}-${pkgver}/nemo-extension/${pkgname}/locale/. ${pkgdir}/usr/share/nemo-python/extensions/${pkgname}/locale

from nemo-mediainfo-tab.

yochananmarqos avatar yochananmarqos commented on June 11, 2024

@linux-man Whoops. Got it.

I noticed other extensions install their other files in their own folder in /usr/share/ rather than the extension folder. It might be tidier to have the locale folder in /usr/share/nemo-mediainfo-tab/ instead.

from nemo-mediainfo-tab.

linux-man avatar linux-man commented on June 11, 2024

I see your point. I'm a little torn apart about that.
As a plus, this way the extension can be installed at .local with no changes.
I'll think about it.

from nemo-mediainfo-tab.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.