Skip to content
Snippets Groups Projects
Forked from trisquel / package-helpers
1396 commits behind the upstream repository.
After you've reviewed these contribution guidelines, you'll be all set to contribute to this project.
CONTRIBUTING.md 5.03 KiB

Contributing

Whether you've got a bugfix, documentation update, or new feature for us, these are the steps to follow to contribute code back into the main trisquel repo.

1. Prerequisites

  1. Install needed packages for both, sources and binary builds
sudo apt-get install  dpkg-dev devscripts git pbuilder quilt patch sed rpl parsewiki
  1. Configure build environment for binary packages
git clone https://devel.trisquel.info/trisquel/trisquel-builder.git
ln -s $(readlink -f trisquel-builder/pbuilderrc) ~/.pbuilderrc
sudo ln -s $(readlink -f trisquel-builder/hooks) /var/cache/pbuilder/hooks.d
  1. Create the build environment for each distribution/architecture you want to work with
sudo BUILDDIST=belenos BUILDARCH=amd64 pbuilder create 

2. Get the latest code from gitlab

You'll need to understand a little bit about how git and gitlab work before this step (GitHub works the same way, but we like free software). In simple terms, log in here, visit the trisquel/package-helpers project page, and click the "fork" button to create your own copy of the repo. You will push your changes to this new repo under your own git account, and we will pull changes into the main repo from there.

For the sake of the rest of the examples in this guide, we're going to assume your gitlab username is "richardtorvalds" and you will be working with the "hello" package, and use those in our examples.

Now, we want to grab the latest from this newly created repository and pull it down to your local machine. Getting the latest code from your repo is simple, just clone it:

git clone https://devel.trisquel.info/richardtorvalds/package-helpers.git
cd package-helpers

This will give you a directory called "package-helpers" on your local machine with the latest checkout from your fork of the main package-helpers repo. Note: this is not a direct reference to the main trisquel repo. When you make changes in your fork, you'll need to let us know about it so we can pull it over....but that's later in the process.

3. Add a remote for the main package-helpers repo

One thing you'll need to do to make things easier to integrate and keep up to date in your fork is to add the main repo as a remote reference. This way you can fetch the latest code from the production version and integrate it. So, here's how to set that up:

git remote add upstream https://devel.trisquel.info/trisquel/package-helpers.git
git remote   (this will list out your remotes, showing the new one we added)

Then, when you need to pull the latest from the main trisquel repo, you just fetch and merge the master branch:

git fetch upstream
git merge upstream/belenos