altdesktop / i3-style

🎨 Make your i3 config a little more stylish.
https://crates.io/crates/i3-style
Other
676 stars 30 forks source link

RPM Packaging #19

Open williamjmorenor opened 8 years ago

williamjmorenor commented 8 years ago

Hi

I am working in package i3-style in Fedora, but I am not placing anything under /usr/bin , so there is not command line tool in the $Patch of the user.

https://bugzilla.redhat.com/show_bug.cgi?id=1274934

I am missing some step in the build of this app?

acrisci commented 8 years ago

I don't know much about RPM packaging, so I'm not sure if I will be of much help. I personally just use fpm for packaging when I need to make packages for Debian or Fedora.

Packaging this should be the same as packaging any other node project. There is probably some good documentation out there for that.

The recommended way to install for packaging is with npm install -g i3-style. Look at the npm documentation for what is actually going on there.

Try stat $(which i3-style) and you will see it is a symlink.

File: ‘/usr/bin/i3-style’ -> ‘../lib/node_modules/i3-style/lib/cli.js’

Hope that gives you something to go on. Thanks for your interest in packaing the project. Let me know if you have any more specific questions and I will support you the best I can.

williamjmorenor commented 8 years ago

A symlink!

Thanks, there is many dependencies not available, i need some one to review it but the package is on the go.

acrisci commented 8 years ago

npm packages do not rely on external dependencies. They carry all their dependencies with them. Look at the contents of /usr/lib/node_modules/i3-style/node_modules. Those are the only dependencies i3-style uses. They should be downloaded by npm.

williamjmorenor commented 8 years ago

Yes this is true with npm packaging, packages .deb .rpm or similars can not get dependencies out the system repository, so all depencies need to be packaged alongside the app to work.

You can see the dependency tree of i3-style in redhat:

https://bugzilla.redhat.com/showdependencytree.cgi?id=1274934&hide_resolved=1

There are 4 missing depencies.

acrisci commented 8 years ago

Do you need any more help or should I close?

perskes commented 8 years ago

not working for me, I don't have the symlink in my path, and If I create it, it says "/usr/bin/env: ‘node’: No such file or directory" when I execute it.

this is what it said after installing it. ➜ ~ sudo npm install i3-style /usr/local/bin/i3-style -> /usr/local/lib/node_modules/i3-style/lib/cli.js /usr/local/lib └── i3-style@0.9.0

perskes commented 8 years ago

For anyone curious about the fix: ln -s /usr/bin/nodejs /usr/bin/node

digitalmediums commented on Sep 27, 2012 I've found this is often a misnaming error, if you install from a package manager you bin may be called nodejs so you just need to symlink it like so "ln -s /usr/bin/nodejs /usr/bin/node"