LoopPerfect / buckaroo

The decentralized package manager for C++ and friends 🏝️
https://buckaroo.pm
MIT License
933 stars 33 forks source link

How to add specific version on a specific branch of git repo? #368

Closed SeanRamey closed 4 years ago

SeanRamey commented 4 years ago

How are you supposed to buckaroo add a certain commit version of a github package? The [@<version>] just doesn't work, except when the [@<version>] is a tag.

So, here's an example: $ buckaroo add github.com/SFML/SFML@50e173e403ef8912e3d8ac3c7ab3e27e32243339 Error in Ln: 1 Col: 28 add github.com/SFML/SFML@50e173e403ef8912e3d8ac3c7ab3e27e32243339                                                ^ Expecting: decimal digit, end of input, whitespace, '--cache-first', '--verbose' or '.'

This is the commit: https://github.com/SFML/SFML/commit/50e173e403ef8912e3d8ac3c7ab3e27e32243339

As of right now, this is completely unusable.

Arch Linux 5.6.3-arch1-1

nikhedonia commented 4 years ago

Thanks for opening this issue.

Buckaroo currently uses a slightly more verbose syntax of @revision=<HASH> and can only install packages that have a buckaroo.toml in it's repository.

We forked SFML and added a buckaroo.toml here: https://github.com/buckaroo-pm/SFML

Hence you can install it via:

buckaroo add github.com/buckaroo-pm/SFML@revision=cb1fecade04b317eb763ad8b07f288319ce4e9a1

or

buckaroo add github.com/buckaroo-pm/SFML@branch=master

More info about version constraints here: https://github.com/LoopPerfect/buckaroo/wiki/Version-Constraints-DSL