|
1 | 1 | # fpkg |
2 | | -`fpkg` stands for "`f`oreign `p`ac`k`a`g`e". |
| 2 | +This name stands for *f*oreign *p*ac*k*a*g*e! |
3 | 3 |
|
4 | | -## what are foreign packages, though? |
| 4 | +### And what is a "foreign package"? |
5 | 5 |
|
6 | | -this is how i call packages that are not available in the repositories the user currently has, meaning they take them from other sources |
| 6 | +That is how I call packages not available on the repositories of an user. It can be from any source but those, although this script currently supports GitHub only. |
7 | 7 |
|
8 | | -in this script, currently only sources from a git repository are supported |
| 8 | +### How does it work? |
9 | 9 |
|
10 | | -## how's that work? |
| 10 | +`fpkg` needs 2 files in order to run: the text file `pkg.list` and the directory `ii/`. |
11 | 11 |
|
12 | | -you have 2 files: `pkg.list` and `pkg.ii` files. both of them are on the default fpkg directory, `/usr/local/fpkg/` |
| 12 | +`pkg.list` contains a newline-separated list of all packages, and you currently have to register them manually. You can easily do this by running `fpkg add`. |
13 | 13 |
|
14 | | -`pkg.list` contains the list of packages the user has registered |
| 14 | +This list is currently being used solely for `fpkg` to know which packages it has to update. The update happens by simply issuing `git pull` inside the selected directory :) |
15 | 15 |
|
16 | | -"ii" stands for "`i`nstallation `i`nstructions", and files containing that extension are used by fpkg for installing packages. since there's no standard way of installing packages, that was the solution i came up with lol |
| 16 | +`ii/` contains little scripts written manually for installation of packages. |
17 | 17 |
|
18 | | -.ii files are made during the package registration process, the user has to type everything necessary for that package to install, like `./configure; make; make install` |
| 18 | +Since not every package uses the same steps for building, that was the solution I came up with. `fpkg add` already redirects you to write those steps using your favorite text editor, though! |
19 | 19 |
|
20 | | -the script is written entirely in bash. i originally wanted to make it in c, but nah |
| 20 | +### Setup |
| 21 | + |
| 22 | +Just put the script somewhere in your `$PATH`. I use `/usr/local/bin/` for it. |
| 23 | + |
| 24 | +As for the directory containing all packages, that is literally the first line of code (after the classic `#!/bin/bash` of course). You just change `$FPKGDIR` to whatever you want. |
| 25 | + |
| 26 | +And for the text editor, it's also as simple. Change `$EDITOR` to your favorite text editor. |
| 27 | + |
| 28 | +That's it, you're good to go! Don't forget to run `fpkg help` to get some extra stuff as well :) |
0 commit comments