Package: libreselery
Continuous FundingLibreSelery is a tool to distribute funding in free and open source projects. With a new funding model it offers transparent, automated and adaptable compensation of contributors. The aim is to replace the middleman of donation distribution as far as possible with a free and transparent algorithm.This project is funded by LibreSelery itself. If you contribute to this repository, you will receive portation from the pool to your public email address.ConceptLibreSelery is a simple command line tool that runs upon any git project manuely or automated by continuous integration. It creates as a donation pool collecting cryptocurrency in a wallet. At each run an amount is taken from the donation pool and distributed to the project's contributors and dependencies.It is designed to run in a continuous integration pipeline like GitHub Actions. Donation transactions are automatically handled and transaction details are published for transparency into the wiki of your repository with a donation page of your project.Donations are divided between contributors based on a public and transparent metric.
The metric can be configured per repository and is based on the following weights:Uniform Weight: Everyone who contributed a minimum number of commits to the main branch is consideredActivity Weight: Everyone who contributed in the last X commitsService Weight: Everyone who contributed to successful pull requests based on issues in the last X commits (not implemented yet#132)More weights are under active development and will be added in the future.The amount distributed to each contributor is calculated from an accumulation of these weights.
It is sent via the cryptocurrency market API to the public email address of the git platform user profile.
You can even activate to compensate contributors from your dependencies.ImplementationLibreSelery ...is configured based on the selery.yml file and runs as a GitHub Action on your project.is triggered with every push on the main branch by the GitHub Action worflow file that is part of your project repository.gathers contributor information about the target project via the GitHub and Libraries.io API.filters out contributors with a hidden email address in the github profile and below the minimum contribution limit. LibreSelery will not send emails to the git commit email addresses in order to avoid spam.creates custom funding distribution weights based on the contribution rating of various projects: Minimum contribution, activity, ...adds the weights to the combined weight used for different distribution splitting behaviors.distributes the funding between the contributors based on the selected split behavior.pays out cryptocurrency to the selected contributors' email addresses via the Coinbase API. Contributors without a Coinbase account will receive an email to claim the donation.generates automatically a dotation and transaction visualization website in your GitHub wiki.FeaturesTransparentpayout of GitHub project contributors with every push you make to your main (master) branch.Minimal changes to your GitHub project shown in theseleryexampleto adapt LibreSelery with just a view steps.Detailedtransaction historyis regenerated in your github wiki every time you run LibreSelery.User defined payout configurationby theselery.yml.Dependency scanning for most languages toeven include developers of your dependenciesusingLibraries.io.The money is distributed via Coinbase. Other payment methods like Uphold are currently work in progress.Donators can see transparent payout logs inGitHub Action.Self-hosteddonation websitefor secure donations is automatically stored in the Wiki of your repository.Simulate the money distribution for your repository without actually transferring money to see how the money would be distributed.Automated statistic generation on how much money was paid out to which contributor.Splitting Strategies:full_split - All contributors receive a payout according to their weight.random_split - X contributors are randomly picked using the weight as probability.Getting StartedSince the project is in its early stages the amount of funding on your wallet should therefore be limited.GitHub Actions IntegrationUse the templateseleryactionto integrate LibreSelery into any GitHub project. Starting with GitHub Actions integration is the easiest way for newcomers and people without Linux knowledge.Command Line UsageRunning with DockerInstallDocker:cd~
gitclonehttps://github.com/protontypes/libreselery.gitcdlibreselery
./build.shCreate a token file for your user, where you store API keys and secrets:mkdir-p~/.libreselery/secrets~/.libreselery/results/public
touch~/.libreselery/secrets/tokens.envLibreSelery just needs API tokens fromGitHubwhensimulation = Trueandinclude_dependencies = Falsein yourselery.yml. The scope of your github token should not include any additional permissions beyond the standard minimum scope. Find out more about how to create GitHub tokenshere. Replace XXXXX with the Coinbase andLibraries.iotokens to get started without creating an actual accounts for these APIs.Make the token file read only:chmod400~/.libreselery/secrets/tokens.envClone your target repository:gitclone<target_repository>Copy aselery.ymlinto your <target_repository>.  Setsimulation: Falsein your selery.yml to enable payouts with LibreSelery.Adjust and test different configurations in simulation mode on your repository project.Create a dedicated Coinbase account with limited amounts. Coinbase does not support sending emails to yourself. That's why you should use a dedicated email address when you are the owner of the Coinbase account and contributor of the project. Otherwise LibreSelery will skip these payouts.Buy some cryptocurrency. See theprice listfor transferring money into the Coinbase account.Configure theaccess control settingsof the automated Coinbase wallet.Never transfer or store large values with automated cryptocurrency wallets. Userecurring automated buysto recharge you wallet on a regular base to avoid financial and security risks. Coinbase does not charge for transferring cryptocurrency from one Coinbase wallet to another.Add your coinbase API keys and secrets to the newly created file (~/.libreselery/tokens.env).  Never store these tokens in a public repository .COINBASE_TOKEN=<your_coinbase_token>COINBASE_SECRET=<your_coinbase_secret>GITHUB_TOKEN=<your_github_tokens>LIBRARIES_API_KEY=<your_libaries_io_tokens>Send cryptocurrency to weighted random product contributors with a valid visible email address on GitHub:env$(cat~/.libreselery/secrets/tokens.env)./run.sh<target_repository>Run directly on your host machineInstall the dependencies on your machine.sudoaptupdate&&sudoaptinstallgitrubyruby-devcurlpython3-pip
pip3install.Ensure that$HOME/.local/binis in$PATH. Check the output ofecho $PATH. If it does not contain.local/binadd the following line to your dotfile for example~/.bashrc.exportPATH=$HOME/.local/bin:$PATHRun LibreSelery on your target project.env$(cat~/.libreselery/secrets/tokens.env)seleryrun-d~/<target_repository>-r~/.libreselery/results/RoadmapLibreSelery is gone support multiple APIs and assets in the near future like:GitHubGitlabSavannahLibraries.ioCoinbaseUpholdSupport LibreSeleryDonationsCertainly we are funded by LibreSelery over direct donations via ourdonation website. The usage and development of LibreSelery will always be free and without any charges. If you want to support us by using LibreSelery you need to add us to thetooling_repos.yml.ContributionsThose who have contributed to the master branch receive emails with cryptocurrency from Coinbase. Only git profiles with emails on the GitHub profile page will be considered.
Find out more in thecontribution guideor look into thegood first issuelabels to get into the project with some first simple tasks.Contact and FeedbackFor further information please contact us atteam_at_protontypes.eu, join ourGitter chator check out ourwiki.Artwork by Miriam Winter andundraw