-
Notifications
You must be signed in to change notification settings - Fork 0
Create or update packages
Basic to intermediate git
and bash
knowledge, intermediate to expert linux knowledge is required.
- Prerequisites
- Hazel documentation
- Basic bash
- Basic git
Tips:
A
stock-linux
folder can contain all of the things reladed to stock-linux.
A recipe is ordered like so:
name=
version=
release=
description=
source=
packager=
makedepends=
# Some functions, for later
What is what ?
-
name
: Name of the package -
version
: Version of the package -
release
: Revision of the package at the version $version -
description
: Description of the package -
source
: Source URL -
packager
: Packager of the package; your name/pseudo -
makedepends
: Packages needed to build the package
You have the following functions that can be created:
-
unpack
: Called whenhazel
unpack the source. To use if the source got some issues when unpacking it. -
pre_build
: Called before build. -
build
(needed): Called at build time. To build the package.-
build_python
: Callable from thereceipe
inbuild
function. To build python modules that respect the standards. Already created, just specify it -
build_meson
: Callable from thereceipe
inbuild
function. To build meson packages that respect standards. Already created, just specify it
-
-
post_build
: Called after the end of the build. To configure some files if needed for instance.
There are two ways: GUI and CLI.
Just fork the packages using Github and clone it on your system:
git clone https://github.com/<username>/<repo_name>
Be careful to always sync your fork
To do that, go on your github fork and click on "sync". Then git pull
on your local repo.
First you need to have the packages on your PC.
git clone https://github.com/stock-linux/packages
Then create a repo on github, and add it as a remote in your local repo.
git remote add fork https://github.com/<username>/<repo_name>`
Now, every time you push, you should do: git push fork
.
Be careful to always sync your fork
To do that,
git fetch origin
git checkout testing
git rebase origin/testing
You need to have the tools and the packages repo on your PC.
And do
cd packages # if you are not inside the repo yet
git checkout testing
mkdir <type>/<package_name>
hazel new <type>/<package_name> <version> <source> "<description">
If you have an error saying your EDITOR variable is not set, do
global EDITOR=<your_prefered_editor>
And relaunch hazel
.
Now you should have <type>/<package_name>/recipe
file opened. You can set the release
variable to 1 and set the makedepends
variable if needed like that: (<dep1> <dep2> ...)
.
To build the package, run
hazel <package>
and wait..
If you have any error, read the output and the logs located in ~/hazel/logs/<package>-<version>.log
and if you need help, you can go on our discord server.
Launch hazel <package> <new_version>
First, take a look at recipe-organizarion.
Apply your changes, increment the variable <release>
by 1 and build the package.
TODO
Every package in the pull request should be working, at least a little.
The title is built like that:
For creation
Add <package>-<version>
For update
Update <package>-<old_version> to <version>
Link any issue in the report when adding your package