isamert / scli

a simple terminal user interface for signal messenger (using signal-cli)
GNU General Public License v3.0
449 stars 39 forks source link

[Question] Easy install for Debian-based distros ? #136

Closed KaKi87 closed 2 years ago

KaKi87 commented 3 years ago

As an APT, PPA or DEB ?

Thanks.

exquo commented 3 years ago

This is similar to #129, with the same upshot: the most involved step in the install process is installing the signal-cli dependency (not that that is normally difficult either). The rest is a matter of entering two-three commands.

A PPA for scli would need to have the .deb's for signal-cli. Similar to how it's now done in AUR and FreshPorts, where both scli and signal-cli are packaged.

In general, for any packaging system, signal-cli should be packaged first. After that adding scli is a cinch.

EDIT: Corresponding issues upstream: https://github.com/AsamK/signal-cli/issues/117 https://github.com/Turasa/libsignal-service-java/issues/13

KaKi87 commented 3 years ago

Couldn't the signal-cli binary be embedded into scli ?

https://github.com/exquo/signal-libs-build/releases/latest

exquo commented 3 years ago

Embedding a signal-cli binary into scli would be a bad idea, since scli is a platform-independent python application, whereas the signal-cli binaries are specific to the OS and processor architecture. (This variety is why there are so many files listed in the 'releases' link you quote).

KaKi87 commented 3 years ago

My request consists in creating distributable packages and those will be platform-dependent anyway.

exquo commented 3 years ago

The way to do this is to create .debs for signal-cli (which would contain platform-dependent binaries) and a .deb for scli (which would be platform-independent and require signal-cli).

This can be done, just hasn't been yet. Technically, this is outside of this repo scope, since the main step is packaging signal-cli.

KaKi87 commented 3 years ago

Why not putting both in it so it can be done faster ?

exquo commented 3 years ago

Yes, maybe someone can package both .debs, and maintain a single PPA.

KaKi87 commented 3 years ago

That would be nice, because, until then, scli is not easily accessible for most Linux users.

morph027 commented 2 years ago

FTR, I've started some work in https://packaging.gitlab.io/signal-cli/ (Git: https://gitlab.com/packaging/signal-cli)

As i'm using fpm, these packages should work for Debian too. The repo could be updated to server for Debian as well, not just Ubuntu.

exquo commented 2 years ago

@morph027 Nice! If you will be packaging scli as well, let us know if we can help!

morph027 commented 2 years ago

Sure. Will add another repo and let you know ;)

morph027 commented 2 years ago

Repo for scli: https://gitlab.com/packaging/scli/.

Requires [signal-cli repo](https://packaging.gitlab.io/signal-cli].

ATM, only focal is in the list of distributions as it needs more testing.

exquo commented 2 years ago

@morph027 That's awesome! (And fast!) I'll add a link to the README.

I've tested it on Debian 11 (bullseye), and it seems to work fine with the focal repositories. The only thing I've had to change in the instructions was the line

sudo apt-get install python3-scli

(i.e. added python3-), which is probably just a typo.

Could you please add another package to the dependencies: python3-pyqrcode (available in the focal repos)? It is optional (used for running scli link), but I think wouldn't hurt.

Running scli --version prints out ? (see https://github.com/isamert/scli/issues/151#issuecomment-1004412178 for how scli determines its version at runtime). I guess fpm does not bundle the VERSION file, and most likely does not run git archive. This is a very minor issue though. The users can run apt show python3-scli instead. Also, we need to add scli to PyPI anyway (see #129). Then you script could use pip install and will get the right VERSION.

Thanks again!

morph027 commented 2 years ago

Great. I've added python3-pyqrcode as dependency, added the VERSION file and added a repo for bullseye too.

README has been updated.

root@529ee67b1ca5:/# apt-cache policy python3-scli
python3-scli:
  Installed: 0.6.6-2
  Candidate: 0.6.6-2
  Version table:
 *** 0.6.6-2 500
        500 https://packaging.gitlab.io/scli/repo-focal focal/main amd64 Packages
        100 /var/lib/dpkg/status
root@529ee67b1ca5:/# scli --version
scli 0.6.6
root@529ee67b1ca5:/#

Will add bullseye for signal-cli repo too.

exquo commented 2 years ago

Left an issue on the project's gitlab

KaKi87 commented 2 years ago

So have I