rust-script icon indicating copy to clipboard operation
rust-script copied to clipboard

Provide Debian package in Releases

Open clintfred opened this issue 2 years ago • 1 comments

If a debian package were provided, rust-script could be easily installed/uninstalled on Debian-based systems.

One approach might be to use the excellent cargo-deb

It just worked out of the box for me.

rust-script git:main  
❯ cargo deb
   Compiling version_check v0.9.4
   ...
   Compiling toml v0.7.6
   Compiling rust-script v0.34.0 (/workspace/rust-script)
    Finished release [optimized] target(s) in 22.41s
/workspace/rust-script/target/debian/rust-script_0.34.0_amd64.deb

rust-script git:main  23s
❯ cd target/debian 

rust-script/target/debian git:main  
❯ ls
rust-script_0.34.0_amd64.deb  rust-script.tmp0-stripped
                                                                                                                                                                                              
rust-script/target/debian git:main  
❯ sudo apt install -f ./rust-script_0.34.0_amd64.deb 

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'rust-script' instead of './rust-script_0.34.0_amd64.deb'
The following NEW packages will be installed:
  rust-script
0 upgraded, 1 newly installed, 0 to remove and 131 not upgraded.
Need to get 0 B/922 kB of archives.
After this operation, 3,143 kB of additional disk space will be used.
Get:1 /workspace/rust-script/target/debian/rust-script_0.34.0_amd64.deb rust-script amd64 0.34.0 [922 kB]
Selecting previously unselected package rust-script.
(Reading database ... 302606 files and directories currently installed.)
Preparing to unpack .../rust-script_0.34.0_amd64.deb ...
Unpacking rust-script (0.34.0) ...
Setting up rust-script (0.34.0) ...
                                                                                                                                                                                                                                                                                                                                                              
rust-script/target/debian git:main  
❯ rust-script /tmp/hello.rs 
Hello world

I have good luck combining this with cross to build debians for various OS/arch/libc triples.

clintfred avatar Nov 28 '23 00:11 clintfred

Would like to see a debian package provided as well.

trymeouteh avatar Oct 23 '24 00:10 trymeouteh