Git Product home page Git Product logo

customizepkg's Introduction

customizepkg

A tool for Arch Linux package manager pacman to modify PKGBUILD automatically.

Usage:

Without any parameters, it will read ./PKGBUILD and show any modifications that would be done. Create config files with the same name as the package you want to modify, and place in either: /etc/customizepkg.d/ or ~/.customizepkg/. You can export the environment variable $CUSTOMIZEPKG_CONFIG to change the directory customizepkg will look for the config files in.

The pacman wrapper "Yaourt" integrates with customizepkg by default

Configuration file Syntax:

ACTION#CONTEXT#PATTERN#VALUE
  • Action can be: remove, removeline, add, addline or replace
  • Context can be: depends, conflicts, makedepends etc.. or global for matching regexp in the whole PKGBUILD
  • Pattern can be any rexgexp
  • Value (only needed for replace) can be any string
  • Comments can be added by starting the line with #
  • The seperator can be changed by adding "@SEPARATOR=" to a configfile

Additional Files

You can add extra files to a PKGBUILD by placing them in /etc/customizepkg.d/$PACKAGENAME.files/ They will be added automatically, including checksums

Run a script

If the configuration file has the executable flag set, it will be executed instead of parsed. Two parameters are passed to the script:

  • $1 is the original PKGBUILD
  • $2 is the custom PKGBUILD

Patch the source

Patch files can be applied to the source code using the following syntax:

patch#1#file.patch
  • The context ("1" above) is the number of leading components to strip (i.e. patch -p1)
  • The path cannot contain variables
  • The patch file can be stored in the additional files directory, $PACKAGENAME.files

You can also patch the PKGBUILD with the following syntax:

patch#pkgbuild#file.patch

customizepkg's People

Contributors

ava1ar avatar dffischer avatar dmitrik avatar nogweii avatar stevenhoneyman avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.