Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
PKG-TRIGGERS(5)		      File Formats Manual	       PKG-TRIGGERS(5)

NAME
       triggers	-- trigger file	format

DESCRIPTION
       triggers	are executed at	the end	of the transactions: installation, de-
       installation or upgrade.	 They are only executed	once even if they have
       been triggered multiple times.

       are  triggered by pattern matching during the transaction. triggers are
       files located in	/usr/local/share/pkg/triggers Those files are  in  UCL
       format and should use a .ucl extension.

       The format is the following:

       path	    exact  path	 to match: each	time a package installs	a file
		    or directory exactly matching the path the trigger will be
		    executed at	the end	of the transation .

       path_glob    glob path to match:	each time a package installs a file or
		    directory which matches the	glob pattern pattern the trig-
		    ger	will be	executed at the	end of the transation .

       path_regexp  regexp path	to match: each time a package installs a  file
		    or	directory which	matches	the regexp pattern pattern the
		    trigger will be executed at	the end	of the transation .

       cleanup	    Object which represent the script to execute in  case  the
		    transaction	results	in removal of the trigger from the in-
		    stallation.	 The object requires the following fields:

		    type    The	 type  of the script to	be executed, currently
			    only    lua	   script    is	    supported	  (See
			    pkg-lua-script(5)).

		    script  The	script itself.

       trigger	    Object which represent the script to execute at the	end of
		    the	 transaction  if a pattern has been matched.  This ob-
		    ject requires the following	fields:

		    type    The	type of	the script to be  executed,  currently
			    only     lua     script    is    supported	  (See
			    pkg-lua-script(5)).

		    script  The	script itself.	It will	receive	 as  arguments
			    the	list of	paths that matched the patterns	during
			    the	transaction.

SEE ALSO
       pkg_create(3),	 pkg_printf(3),	   pkg_repo_create(3),	 pkg_repos(3),
       pkg-keywords(5),	pkg-lua-script(5),  pkg-repository(5),	pkg-script(5),
       pkg.conf(5),   pkg(8),	pkg-add(8),   pkg-alias(8),   pkg-annotate(8),
       pkg-audit(8),	pkg-autoremove(8),     pkg-check(8),	 pkg-clean(8),
       pkg-config(8), pkg-create(8), pkg-delete(8), pkg-fetch(8), pkg-info(8),
       pkg-install(8), pkg-key(8), pkg-lock(8),	pkg-query(8), pkg-register(8),
       pkg-repo(8),    pkg-repositories(8),    pkg-rquery(8),	pkg-search(8),
       pkg-set(8),  pkg-shell(8),  pkg-shlib(8),   pkg-ssh(8),	 pkg-stats(8),
       pkg-update(8),	 pkg-updating(8),    pkg-upgrade(8),   pkg-version(8),
       pkg-which(8)

FreeBSD	Ports 14.quarterly     September 9, 2021	       PKG-TRIGGERS(5)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=pkg-triggers&sektion=5&manpath=FreeBSD+Ports+14.3.quarterly>

home | help