packages and services management
Log | Files | Refs | README

commit 81f1a467f02b2e8792f04b698742f880084f1e37
parent 8cee28246394c3889d4e921db7478340ab913a99
Author: Josuah Demangeon <>
Date:   Sat, 22 Dec 2018 16:59:35 +0100

switch to stagit

Dbin/git-all | 9---------
Dbin/git-count | 4----
Dbin/git-dog | 3---
Abin/git-hook-fetch | 4++++
Abin/git-hook-stagit | 30++++++++++++++++++++++++++++++
Abin/git-newrepo | 27+++++++++++++++++++++++++++
Abin/git-newrepo-stagit | 12++++++++++++
Dbin/git-s | 4----
Dbin/git-stat | 3---
Dbin/git-update | 7-------
Mbin/service-compile | 7++++---
Mbin/service-init | 38++++++++++++++++++--------------------
Aconf/git | 11+++++++++++
Metc/pack/httpfile/build | 46++++++++++++++++++++++++++++++++++++++++++++++
Aetc/pack/httpfile/filetype.txt | 985+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Metc/pack/libgit2/build | 27++++++++++++++-------------
Metc/pack/stagit-gopher/ | 21+++++----------------
Aetc/pack/stagit-gopher/dependencies/libgit2 | 1+
Aetc/pack/stagit-gopher/dependencies/libressl | 1+
Metc/pack/stagit/ | 17+++--------------
Aetc/pack/stagit/dependencies/libgit2 | 2++
Aetc/pack/stagit/dependencies/libressl | 2++
Aetc/s6/qmail-send/x/env/GROUP | 1+
Aetc/s6/qmail-send/x/env/USER | 1+
Metc/s6/qmail-send/x/setup | 9++++++---
25 files changed, 1173 insertions(+), 99 deletions(-)

diff --git a/bin/git-all b/bin/git-all @@ -1,9 +0,0 @@ -#!/bin/sh -e -# execute arguments for each git directories found in pwd - -find $PWD -name .git | while IFS='' read -r repo -do cd "$(dirname "$dir")" - printf '\n%-50s' "$(pwd)" >&2 - git status -s --branch >&2 - "$@" -done diff --git a/bin/git-count b/bin/git-count @@ -1,4 +0,0 @@ -#!/bin/sh -e -# print the summary of lines added vs removed - -expr "$(git diff | grep '^+' | wc -l)" - "$(git diff | grep '^-' | wc -l)" diff --git a/bin/git-dog b/bin/git-dog @@ -1,3 +0,0 @@ -#!/bin/sh -e - -git log --all --graph --decorate --branches --date short --oneline diff --git a/bin/git-hook-fetch b/bin/git-hook-fetch @@ -0,0 +1,4 @@ +#!/usr/bin/env execlineb + +if { git config remote.origin.fetch 'refs/heads/*:refs/heads/*' } +if { git remote update } diff --git a/bin/git-hook-stagit b/bin/git-hook-stagit @@ -0,0 +1,30 @@ +#!/usr/bin/env execlineb + +s6-envdir env +importas -D 0 target PATH_WWW + +backtick -n x { basename ${target} } +importas domain x + +backtick -n x { pwd } +importas repo x + +backtick -n x { basename ${repo} .git } +importas repo x + +cd ${target}/${repo} + +if { stagit -l ${limit} -c ${repo}/stagit-cache ${repo} } +if { stagit-gopher -b ${domain} -l ${limit} -c ${repo}/stagit-cache ${repo} } + +if { + elglob -0 x ${target}/*/ + redirfd -w 1 ${target}/index.html + stagit-index ${x} +} + +if { + elglob -0 x ${target}/*/ + redirfd -w 1 ${target}/index.html + stagit-index-gopher -b ${domain} ${x} +} diff --git a/bin/git-newrepo b/bin/git-newrepo @@ -0,0 +1,27 @@ +#!/usr/bin/env execlineb + +importas -i repo 1 + +define domain +define path_git /var/git +define path_www /var/www/plain + +backtick -n x { dirname ${repo} } +importas repo_dir x + +# the repo may already exist +if { git init --bare ${repo} } + +# configuration +if { mkdir -p ${repo}/env } +if { redirfd -w 1 ${repo}/env/PATH_WWW echo ${path_www}/${domain} } + +# hooks +forx x { pre-receive update post-receive } +importas hook x +if { mkdir -p ${repo}/hooks/${hook}.d } +if { redirfd -w 1 ${repo}/hooks/${hook} printf "%s\n" + "#!/usr/bin/env execlineb" + "elglob -0 x hooks/${hook}.d/*" "forx x { ${x} }" + "importas script x" "${script}" } +if { chmod +x ${repo}/hooks/${hook} } diff --git a/bin/git-newrepo-stagit b/bin/git-newrepo-stagit @@ -0,0 +1,12 @@ +#!/usr/bin/env execlineb + +importas -i repo 1 +importas -i desc 2 + +cd /var/git/${repo} + +backtick -n x { which git-hook-stagit } +importas path x + +if { cp ${path} hooks/update.d } +if { redirfd -w 1 description echo "${desc}" } diff --git a/bin/git-s b/bin/git-s @@ -1,4 +0,0 @@ -#!/bin/sh -e -# short status - -git status -s --branch diff --git a/bin/git-stat b/bin/git-stat @@ -1,3 +0,0 @@ -#!/bin/sh -e - -git log --all --graph --decorate --branches --stat "$@" diff --git a/bin/git-update b/bin/git-update @@ -1,7 +0,0 @@ -#!/bin/sh -e - -test $# = 0 && exec echo 'usage: git update <repo>' - -cd "$1" -git config remote.origin.fetch 'refs/heads/*:refs/heads/*' -git remote update diff --git a/bin/service-compile b/bin/service-compile @@ -27,8 +27,8 @@ if { if { mkdir -p source compiled } if { s6-rc-compile compiled/${time} source } - if { s6-ln -nsf compiled/${time} current } - s6-rc-update -l /var/s6/live /var/s6/compiled/${time} + if { s6-ln -nsf ${time} compiled/current } + s6-rc-update -l /var/s6/live/live /var/s6/compiled/${time} } # bundle the service,x and service,log @@ -45,6 +45,7 @@ if { backtick x { if { test -d ${bundle},log } echo ${bundle},log } importas -s -d "\n" logger x - s6-rc-bundle -fb -l /var/s6/live -c /var/s6/current + if -t { pipeline { s6-rc-db list all } grep -Fqvx -- ${bundle} } + s6-rc-bundle -fb -l /var/s6/live/live -c /var/s6/compiled/current add ${bundle} ${bundle},x ${logger} } diff --git a/bin/service-init b/bin/service-init @@ -1,22 +1,20 @@ #!/usr/bin/env execlineb -if { s6-mkdir -p /var/s6/source /var/s6/compiled /var/s6/scandir } -cd /var/s6 - -if { elglob -0 x scandir/* rm -rf ${x} } -if { elglob -0 x live* rm -rf ${x} } +if { mkdir -p /var/s6 } cd /var/s6 +if { s6-mkdir -p source compiled live /run/s6 } +if { elglob -0 x live/* rm -rf /run/s6 ${x} } # logger -if { s6-mkdir -p scandir/logger } -if { s6-mkfifo scandir/logger/fifo } -if { redirfd -w 1 scandir/logger/run printf "%s\n" +if { s6-mkdir -p /run/s6/logger } +if { s6-mkfifo /run/s6/logger/fifo } +if { redirfd -w 1 /run/s6/logger/run printf "%s\n" "#!/usr/bin/env execlineb" "fdmove -c 2 1" "redirfd -rnb 0 fifo" "s6-log -bp t /var/log/s6" } -if { s6-chmod 0755 scandir/logger/run } -if { redirfd -w 1 scandir/logger/type echo "longrun" } +if { s6-chmod 0755 /run/s6/logger/run } +if { redirfd -w 1 /run/s6/logger/type echo "longrun" } # ok-all if { s6-mkdir -p source/ok-all } @@ -27,23 +25,23 @@ background { backtick -n x { s6-clock } importas t x - ifthenelse { test ! -h current } { + ifthenelse { test ! -h compiled/ current } { if { s6-rc-compile compiled/${t} source } - if { s6-ln -sfn compiled/${t} current } + if { s6-ln -sfn compiled/${t} compiled/ current } } { } # wait that s6-svscan starts - redirfd -w 1 scandir/logger/log + redirfd -w 1 /run/s6/logger/log - if { s6-rc-init -d -c current -l /var/s6/live /var/s6/scandir } - if { s6-ln -sf /var/s6/live /run/s6-rc } - if { s6-rc -l live -u change s6rc-fdholder } - if { s6-rc -l live -u change s6rc-oneshot-runner } - if { s6-rc -l live -u change ok-all } + if { s6-rc-init -d -c compiled/ current -l /var/s6/live /run/s6 } + if { s6-ln -sf /var/s6/live/live /run/s6-rc } + if { s6-rc -l live/live -u change s6rc-fdholder } + if { s6-rc -l live/live -u change s6rc-oneshot-runner } + if { s6-rc -l live/live -u change ok-all } if { echo srv-init finished to boot } } redirfd -r 0 /dev/null -redirfd -wnb 1 /var/s6/scandir/logger/fifo +redirfd -wnb 1 /run/s6/logger/fifo fdmove -c 2 1 -s6-svscan -t0 /var/s6/scandir +s6-svscan -t0 /run/s6 diff --git a/conf/git b/conf/git @@ -0,0 +1,11 @@ +#!/usr/bin/env execlineb + +if { git-newrepo-stagit dot "packages and services management" } +if { git-newrepo-stagit eel "formatter for ii(1) logs" } +if { git-newrepo-stagit ff2txt "display a farbfeld(5)-formatted image as braille or ascii text" } +if { git-newrepo-stagit ics2txt "awk tool for converting ical to a text digest" } +if { git-newrepo-stagit iomenu "interactive text selection menu" } +if { git-newrepo-stagit miniwi "tiny 4x8 bitmapped font" } +if { git-newrepo-stagit ploot "plot images or real-time plain text from a .csv file" } +if { git-newrepo-stagit plstree "display ls or ps output as directory or process trees" } +if { git-newrepo-stagit tttml "tools for formatting a very basic markdown-like format" } diff --git a/etc/pack/httpfile/build b/etc/pack/httpfile/build @@ -1,5 +1,51 @@ #!/bin/sh -ex +cat <<'EOF' >filetype.c +#include "filetype.h" +#include "str.h" +#include "case.h" + +int filetype(const char *fn,stralloc *contenttype) +{ + const char *x; + const char *result; + long long i; + char ch; + + if (!stralloc_copys(contenttype,"Content-Type: ")) return 0; + + x = fn + str_rchr(fn,'.'); + if (x[str_chr(x,'=')]) + for (i = 0;(i < 100) && (ch = x[i]);++i) { + if ((ch != '=') && (ch != '-') && (ch != ':')) + if ((ch < 'a') || (ch > 'z')) + if ((ch < '0') || (ch > '9')) + continue; + if (ch == '=') ch = '/'; + if (ch == ':') ch = '.'; + if (!stralloc_append(contenttype,&ch)) return 0; + } + else { + result = "text/plain"; + + /* web content */ + if (case_equals(x,".html")) result = "text/html"; +EOF + +while read ext mime; do + printf ' else if (case_equals(x,".%s")) result = "%s";\n' "${ext}" "${mime}" +done <$DEF/filetype.txt >>filetype.c + +cat <<'EOF' >>filetype.c + + if (!stralloc_cats(contenttype,result)) return 0; + } + + if (!stralloc_cats(contenttype,"\r\n")) return 0; + return 1; +} +EOF + make mkdir -p "$PREFIX/bin" cp httpfile-*[!.][!.]? "$PREFIX/bin" diff --git a/etc/pack/httpfile/filetype.txt b/etc/pack/httpfile/filetype.txt @@ -0,0 +1,985 @@ +ez application/andrew-inset +aw application/applixware +atom application/atom+xml +atomcat application/atomcat+xml +atomsvc application/atomsvc+xml +ccxml application/ccxml+xml +cdmia application/cdmi-capability +cdmic application/cdmi-container +cdmid application/cdmi-domain +cdmio application/cdmi-object +cdmiq application/cdmi-queue +cu application/cu-seeme +davmount application/davmount+xml +dbk application/docbook+xml +dssc application/dssc+der +xdssc application/dssc+xml +ecma application/ecmascript +emma application/emma+xml +epub application/epub+zip +exi application/exi +pfr application/font-tdpfr +gml application/gml+xml +gpx application/gpx+xml +gxf application/gxf +stk application/hyperstudio +inkml application/inkml+xml +ink application/inkml+xml +ipfix application/ipfix +jar application/java-archive +ser application/java-serialized-object +class application/java-vm +js application/javascript +json application/json +jsonml application/jsonml+json +lostxml application/lost+xml +hqx application/mac-binhex40 +cpt application/mac-compactpro +mads application/mads+xml +mrc application/marc +mrcx application/marcxml+xml +nb application/mathematica +mb application/mathematica +ma application/mathematica +mathml application/mathml+xml +mbox application/mbox +mscml application/mediaservercontrol+xml +metalink application/metalink+xml +meta4 application/metalink4+xml +mets application/mets+xml +mods application/mods+xml +mp21 application/mp21 +m21 application/mp21 +mp4s application/mp4 +dot application/msword +doc application/msword +mxf application/mxf +dms application/octet-stream +lrf application/octet-stream +mar application/octet-stream +so application/octet-stream +dist application/octet-stream +distz application/octet-stream +pkg application/octet-stream +bpk application/octet-stream +dump application/octet-stream +elc application/octet-stream +deploy application/octet-stream +bin application/octet-stream +oda application/oda +opf application/oebps-package+xml +ogx application/ogg +omdoc application/omdoc+xml +onetoc2 application/onenote +onetmp application/onenote +onepkg application/onenote +onetoc application/onenote +oxps application/oxps +xer application/patch-ops-error+xml +pdf application/pdf +pgp application/pgp-encrypted +sig application/pgp-signature +asc application/pgp-signature +prf application/pics-rules +p10 application/pkcs10 +p7c application/pkcs7-mime +p7m application/pkcs7-mime +p7s application/pkcs7-signature +p8 application/pkcs8 +ac application/pkix-attr-cert +cer application/pkix-cert +crl application/pkix-crl +pkipath application/pkix-pkipath +pki application/pkixcmp +pls application/pls+xml +eps application/postscript +ps application/postscript +ai application/postscript +cww application/prs.cww +pskcxml application/pskc+xml +rdf application/rdf+xml +rif application/reginfo+xml +rnc application/relax-ng-compact-syntax +rl application/resource-lists+xml +rld application/resource-lists-diff+xml +rs application/rls-services+xml +gbr application/rpki-ghostbusters +mft application/rpki-manifest +roa application/rpki-roa +rsd application/rsd+xml +rss application/rss+xml +rtf application/rtf +sbml application/sbml+xml +scq application/scvp-cv-request +scs application/scvp-cv-response +spq application/scvp-vp-request +spp application/scvp-vp-response +sdp application/sdp +setpay application/set-payment-initiation +setreg application/set-registration-initiation +shf application/shf+xml +smil application/smil+xml +smi application/smil+xml +rq application/sparql-query +srx application/sparql-results+xml +gram application/srgs +grxml application/srgs+xml +sru application/sru+xml +ssdl application/ssdl+xml +ssml application/ssml+xml +teicorpus application/tei+xml +tei application/tei+xml +tfi application/thraud+xml +tsd application/timestamped-data +plb application/vnd.3gpp.pic-bw-large +psb application/vnd.3gpp.pic-bw-small +pvb application/vnd.3gpp.pic-bw-var +tcap application/vnd.3gpp2.tcap +pwn application/ +aso application/vnd.accpac.simply.aso +imp application/vnd.accpac.simply.imp +acu application/vnd.acucobol +acutc application/vnd.acucorp +atc application/vnd.acucorp +air application/vnd.adobe.air-application-installer-package+zip +fcdt application/vnd.adobe.formscentral.fcdt +fxpl application/vnd.adobe.fxp +fxp application/vnd.adobe.fxp +xdp application/vnd.adobe.xdp+xml +xfdf application/vnd.adobe.xfdf +ahead application/ +azf application/vnd.airzip.filesecure.azf +azs application/vnd.airzip.filesecure.azs +azw application/ +acc application/vnd.americandynamics.acc +ami application/vnd.amiga.ami +apk application/ +cii application/vnd.anser-web-certificate-issue-initiation +fti application/vnd.anser-web-funds-transfer-initiation +atx application/ +mpkg application/ +m3u8 application/ +swi application/vnd.aristanetworks.swi +iota application/vnd.astraea-software.iota +aep application/vnd.audiograph +mpm application/vnd.blueice.multipass +bmi application/vnd.bmi +rep application/vnd.businessobjects +cdxml application/vnd.chemdraw+xml +mmd application/vnd.chipnuts.karaoke-mmd +cdy application/vnd.cinderella +cla application/vnd.claymore +rp9 application/vnd.cloanto.rp9 +c4d application/vnd.clonk.c4group +c4f application/vnd.clonk.c4group +c4p application/vnd.clonk.c4group +c4u application/vnd.clonk.c4group +c4g application/vnd.clonk.c4group +c11amc application/vnd.cluetrust.cartomobile-config +c11amz application/vnd.cluetrust.cartomobile-config-pkg +csp application/vnd.commonspace +cdbcmsg application/ +cmc application/vnd.cosmocaller +clkx application/vnd.crick.clicker +clkk application/vnd.crick.clicker.keyboard +clkp application/vnd.crick.clicker.palette +clkt application/vnd.crick.clicker.template +clkw application/vnd.crick.clicker.wordbank +wbs application/vnd.criticaltools.wbs+xml +pml application/vnd.ctc-posml +ppd application/vnd.cups-ppd +car application/ +pcurl application/vnd.curl.pcurl +dart application/vnd.dart +rdz application/ +uvvf application/ +uvd application/ +uvvd application/ +uvf application/ +uvvt application/vnd.dece.ttml+xml +uvt application/vnd.dece.ttml+xml +uvvx application/vnd.dece.unspecified +uvx application/vnd.dece.unspecified +uvvz application/ +uvz application/ +fe_launch application/vnd.denovo.fcselayout-link +dna application/vnd.dna +mlp application/vnd.dolby.mlp +dpg application/vnd.dpgraph +dfac application/vnd.dreamfactory +kpxx application/vnd.ds-keypoint +ait application/vnd.dvb.ait +svc application/vnd.dvb.service +geo application/vnd.dynageo +mag application/vnd.ecowin.chart +nml application/vnd.enliven +esf application/ +msf application/ +qam application/ +slt application/ +ssf application/ +et3 application/vnd.eszigno3+xml +es3 application/vnd.eszigno3+xml +ez2 application/vnd.ezpix-album +ez3 application/vnd.ezpix-package +fdf application/vnd.fdf +mseed application/vnd.fdsn.mseed +dataless application/vnd.fdsn.seed +seed application/vnd.fdsn.seed +gph application/vnd.flographit +ftc application/vnd.fluxtime.clip +frame application/vnd.framemaker +maker application/vnd.framemaker +book application/vnd.framemaker +fm application/vnd.framemaker +fnc application/ +ltf application/ +fsc application/vnd.fsc.weblaunch +oas application/ +oa2 application/ +oa3 application/ +fg5 application/ +bh2 application/ +ddd application/ +xdw application/ +xbd application/ +fzs application/vnd.fuzzysheet +txd application/vnd.genomatix.tuxedo +ggb application/vnd.geogebra.file +ggt application/vnd.geogebra.tool +gre application/vnd.geometry-explorer +gex application/vnd.geometry-explorer +gxt application/vnd.geonext +g2w application/vnd.geoplan +g3w application/vnd.geospace +gmx application/ +kml application/ +kmz application/ +gqs application/vnd.grafeq +gqf application/vnd.grafeq +gac application/vnd.groove-account +ghf application/vnd.groove-help +gim application/vnd.groove-identity-message +grv application/vnd.groove-injector +gtm application/vnd.groove-tool-message +tpl application/vnd.groove-tool-template +vcg application/vnd.groove-vcard +hal application/vnd.hal+xml +zmm application/vnd.handheld-entertainment+xml +hbci application/vnd.hbci +les application/vnd.hhe.lesson-player +hpgl application/vnd.hp-hpgl +hpid application/vnd.hp-hpid +hps application/vnd.hp-hps +jlt application/vnd.hp-jlyt +pcl application/vnd.hp-pcl +pclxl application/vnd.hp-pclxl +sfd-hdstx application/vnd.hydrostatix.sof-data +mpy application/ +listafp application/ +list3820 application/ +afp application/ +irm application/ +sc application/ +icm application/vnd.iccprofile +icc application/vnd.iccprofile +igl application/vnd.igloader +ivp application/vnd.immervision-ivp +ivu application/vnd.immervision-ivu +igm application/vnd.insors.igm +xpx application/vnd.intercon.formnet +xpw application/vnd.intercon.formnet +i2g application/vnd.intergeo +qbo application/vnd.intu.qbo +qfx application/vnd.intu.qfx +rcprofile application/vnd.ipunplugged.rcprofile +irp application/vnd.irepository.package+xml +xpr application/ +fcs application/vnd.isac.fcs +jam application/vnd.jam +rms application/ +jisp application/vnd.jisp +joda application/vnd.joost.joda-archive +ktr application/vnd.kahootz +ktz application/vnd.kahootz +karbon application/vnd.kde.karbon +chrt application/vnd.kde.kchart +kfo application/vnd.kde.kformula +flw application/vnd.kde.kivio +kon application/vnd.kde.kontour +kpt application/vnd.kde.kpresenter +kpr application/vnd.kde.kpresenter +ksp application/vnd.kde.kspread +kwt application/vnd.kde.kword +kwd application/vnd.kde.kword +htke application/vnd.kenameaapp +kia application/vnd.kidspiration +knp application/vnd.kinar +kne application/vnd.kinar +skd application/vnd.koan +skt application/vnd.koan +skm application/vnd.koan +skp application/vnd.koan +sse application/vnd.kodak-descriptor +lasxml application/vnd.las.las+xml +lbd application/ +lbe application/ +123 application/vnd.lotus-1-2-3 +apr application/vnd.lotus-approach +pre application/vnd.lotus-freelance +nsf application/vnd.lotus-notes +org application/vnd.lotus-organizer +scm application/vnd.lotus-screencam +lwp application/vnd.lotus-wordpro +portpkg application/vnd.macports.portpkg +mcd application/ +mc1 application/vnd.medcalcdata +cdkey application/vnd.mediastation.cdkey +mwf application/vnd.mfer +mfm application/vnd.mfmp +flo application/vnd.micrografx.flo +igx application/vnd.micrografx.igx +mif application/vnd.mif +daf application/vnd.mobius.daf +dis application/vnd.mobius.dis +mbk application/vnd.mobius.mbk +mqy application/vnd.mobius.mqy +msl application/vnd.mobius.msl +plc application/vnd.mobius.plc +txf application/vnd.mobius.txf +mpn application/vnd.mophun.application +mpc application/vnd.mophun.certificate +xul application/vnd.mozilla.xul+xml +cil application/ +cab application/ +xlm application/ +xla application/ +xlc application/ +xlt application/ +xlw application/ +xls application/ +xlam application/ +xlsb application/ +xlsm application/ +xltm application/ +eot application/ +chm application/ +ims application/ +lrm application/ +thmx application/ +cat application/ +stl application/ +pps application/ +pot application/ +ppt application/ +ppam application/ +pptm application/ +sldm application/ +ppsm application/ +potm application/ +mpt application/ +mpp application/ +docm application/ +dotm application/ +wks application/ +wcm application/ +wdb application/ +wps application/ +wpl application/ +xps application/ +mseq application/vnd.mseq +mus application/vnd.musician +msty application/ +taglet application/vnd.mynfc +nlu application/vnd.neurolanguage.nlu +nitf application/vnd.nitf +ntf application/vnd.nitf +nnd application/vnd.noblenet-directory +nns application/vnd.noblenet-sealer +nnw application/vnd.noblenet-web +ngdat application/ +n-gage application/ +rpst application/ +rpss application/ +edm application/vnd.novadigm.edm +edx application/vnd.novadigm.edx +ext application/vnd.novadigm.ext +odc application/vnd.oasis.opendocument.chart +otc application/vnd.oasis.opendocument.chart-template +odb application/vnd.oasis.opendocument.database +odf application/vnd.oasis.opendocument.formula +odft application/vnd.oasis.opendocument.formula-template +odg application/ +otg application/ +odi application/vnd.oasis.opendocument.image +oti application/vnd.oasis.opendocument.image-template +odp application/vnd.oasis.opendocument.presentation +otp application/vnd.oasis.opendocument.presentation-template +ods application/vnd.oasis.opendocument.spreadsheet +ots application/vnd.oasis.opendocument.spreadsheet-template +odt application/vnd.oasis.opendocument.text +odm application/vnd.oasis.opendocument.text-master +ott application/vnd.oasis.opendocument.text-template +oth application/vnd.oasis.opendocument.text-web +xo application/vnd.olpc-sugar +dd2 application/vnd.oma.dd2+xml +oxt application/vnd.openofficeorg.extension +pptx application/vnd.openxmlformats-officedocument.presentationml.presentation +sldx application/vnd.openxmlformats-officedocument.presentationml.slide +ppsx application/vnd.openxmlformats-officedocument.presentationml.slideshow +potx application/vnd.openxmlformats-officedocument.presentationml.template +xlsx application/vnd.openxmlformats-officedocument.spreadsheetml.sheet +xltx application/vnd.openxmlformats-officedocument.spreadsheetml.template +docx application/vnd.openxmlformats-officedocument.wordprocessingml.document +dotx application/vnd.openxmlformats-officedocument.wordprocessingml.template +mgp application/vnd.osgeo.mapguide.package +dp application/vnd.osgi.dp +esa application/vnd.osgi.subsystem +pqa application/vnd.palm +oprc application/vnd.palm +pdb application/vnd.palm +paw application/vnd.pawaafile +str application/ +ei6 application/ +efif application/vnd.picsel +wg application/vnd.pmi.widget +plf application/vnd.pocketlearn +pbd application/vnd.powerbuilder6 +box application/ +mgz application/vnd.proteus.magazine +qps application/vnd.publishare-delta-tree +ptid application/vnd.pvi.ptid1 +qxt application/vnd.quark.quarkxpress +qwd application/vnd.quark.quarkxpress +qwt application/vnd.quark.quarkxpress +qxl application/vnd.quark.quarkxpress +qxb application/vnd.quark.quarkxpress +qxd application/vnd.quark.quarkxpress +bed application/vnd.realvnc.bed +mxl application/vnd.recordare.musicxml +musicxml application/vnd.recordare.musicxml+xml +cryptonote application/vnd.rig.cryptonote +cod application/vnd.rim.cod +rm application/vnd.rn-realmedia +rmvb application/vnd.rn-realmedia-vbr +link66 application/vnd.route66.link66+xml +st application/vnd.sailingtracker.track +see application/vnd.seemail +sema application/vnd.sema +semd application/vnd.semd +semf application/vnd.semf +ifm application/vnd.shana.informed.formdata +itp application/vnd.shana.informed.formtemplate +iif application/vnd.shana.informed.interchange +ipk application/vnd.shana.informed.package +twds application/vnd.simtech-mindmapper +twd application/vnd.simtech-mindmapper +mmf application/vnd.smaf +teacher application/ +sdkd application/vnd.solent.sdkm+xml +sdkm application/vnd.solent.sdkm+xml +dxp application/vnd.spotfire.dxp +sfs application/vnd.spotfire.sfs +sdc application/vnd.stardivision.calc +sda application/vnd.stardivision.draw +sdd application/vnd.stardivision.impress +smf application/vnd.stardivision.math +vor application/vnd.stardivision.writer +sdw application/vnd.stardivision.writer +sgl application/vnd.stardivision.writer-global +smzip application/vnd.stepmania.package +sm application/vnd.stepmania.stepchart +sxc application/vnd.sun.xml.calc +stc application/vnd.sun.xml.calc.template +sxd application/vnd.sun.xml.draw +std application/vnd.sun.xml.draw.template +sxi application/vnd.sun.xml.impress +sti application/vnd.sun.xml.impress.template +sxm application/vnd.sun.xml.math +sxw application/vnd.sun.xml.writer +sxg application/ +stw application/vnd.sun.xml.writer.template +susp application/vnd.sus-calendar +sus application/vnd.sus-calendar +svd application/vnd.svd +sisx application/vnd.symbian.install +sis application/vnd.symbian.install +xsm application/vnd.syncml+xml +bdm application/ +xdm application/ +tao application/vnd.tao.intent-module-archive +cap application/vnd.tcpdump.pcap +dmp application/vnd.tcpdump.pcap +pcap application/vnd.tcpdump.pcap +tmo application/vnd.tmobile-livetv +tpt application/vnd.trid.tpt +mxs application/vnd.triscape.mxs +tra application/vnd.trueapp +ufdl application/vnd.ufdl +ufd application/vnd.ufdl +utz application/vnd.uiq.theme +umj application/vnd.umajin +unityweb application/vnd.unity +uoml application/vnd.uoml+xml +vcx application/vnd.vcx +vst application/vnd.visio +vss application/vnd.visio +vsw application/vnd.visio +vsd application/vnd.visio +vis application/vnd.visionary +vsf application/vnd.vsf +wbxml application/vnd.wap.wbxml +wmlc application/vnd.wap.wmlc +wmlsc application/vnd.wap.wmlscriptc +wtb application/vnd.webturbo +nbp application/vnd.wolfram.player +wpd application/vnd.wordperfect +wqd application/vnd.wqd +stf application/vnd.wt.stf +xar application/vnd.xara +xfdl application/vnd.xfdl +hvd application/vnd.yamaha.hv-dic +hvs application/vnd.yamaha.hv-script +hvp application/vnd.yamaha.hv-voice +osf application/vnd.yamaha.openscoreformat +osfpvg application/vnd.yamaha.openscoreformat.osfpvg+xml +saf application/vnd.yamaha.smaf-audio +spf application/vnd.yamaha.smaf-phrase +cmp application/vnd.yellowriver-custom-menu +zirz application/vnd.zul +zir application/vnd.zul +zaz application/vnd.zzazz.deck+xml +vxml application/voicexml+xml +wgt application/widget +hlp application/winhlp +wsdl application/wsdl+xml +wspolicy application/wspolicy+xml +7z application/x-7z-compressed +abw application/x-abiword +ace application/x-ace-compressed +dmg application/x-apple-diskimage +x32 application/x-authorware-bin +u32 application/x-authorware-bin +vox application/x-authorware-bin +aab application/x-authorware-bin +aam application/x-authorware-map +aas application/x-authorware-seg +bcpio application/x-bcpio +torrent application/x-bittorrent +blorb application/x-blorb +blb application/x-blorb +bz application/x-bzip +boz application/x-bzip2 +bz2 application/x-bzip2 +cba application/x-cbr +cbt application/x-cbr +cbz application/x-cbr +cb7 application/x-cbr +cbr application/x-cbr +vcd application/x-cdlink +cfs application/x-cfs-compressed +chat application/x-chat +pgn application/x-chess-pgn +nsc application/x-conference +cpio application/x-cpio +csh application/x-csh +udeb application/x-debian-package +deb application/x-debian-package +dgc application/x-dgc-compressed +dcr application/x-director +dxr application/x-director +cst application/x-director +cct application/x-director +cxt application/x-director +w3d application/x-director +fgd application/x-director +swa application/x-director +dir application/x-director +wad application/x-doom +ncx application/x-dtbncx+xml +dtb application/x-dtbook+xml +res application/x-dtbresource+xml +dvi application/x-dvi +evy application/x-envoy +eva application/x-eva +bdf application/x-font-bdf +gsf application/x-font-ghostscript +psf application/x-font-linux-psf +pcf application/x-font-pcf +snf application/x-font-snf +pfb application/x-font-type1 +pfm application/x-font-type1 +afm application/x-font-type1 +pfa application/x-font-type1 +arc application/x-freearc +spl application/x-futuresplash +gca application/x-gca-compressed +ulx application/x-glulx +gnumeric application/x-gnumeric +gramps application/x-gramps-xml +gtar application/x-gtar +hdf application/x-hdf +install application/x-install-instructions +iso application/x-iso9660-image +jnlp application/x-java-jnlp-file +latex application/x-latex +lha application/x-lzh-compressed +lzh application/x-lzh-compressed +mie application/x-mie +mobi application/x-mobipocket-ebook +prc application/x-mobipocket-ebook +application application/x-ms-application +lnk application/x-ms-shortcut +wmd application/x-ms-wmd +wmz application/x-ms-wmz +xbap application/x-ms-xbap +mdb application/x-msaccess +obd application/x-msbinder +crd application/x-mscardfile +clp application/x-msclip +dll application/x-msdownload +com application/x-msdownload +bat application/x-msdownload +msi application/x-msdownload +exe application/x-msdownload +m13 application/x-msmediaview +m14 application/x-msmediaview +mvb application/x-msmediaview +wmz application/x-msmetafile +emf application/x-msmetafile +emz application/x-msmetafile +wmf application/x-msmetafile +mny application/x-msmoney +pub application/x-mspublisher +scd application/x-msschedule +trm application/x-msterminal +wri application/x-mswrite +cdf application/x-netcdf +nc application/x-netcdf +nzb application/x-nzb +pfx application/x-pkcs12 +p12 application/x-pkcs12 +spc application/x-pkcs7-certificates +p7b application/x-pkcs7-certificates +p7r application/x-pkcs7-certreqresp +rar application/x-rar-compressed +ris application/x-research-info-systems +sh application/x-sh +shar application/x-shar +swf application/x-shockwave-flash +xap application/x-silverlight-app +sql application/x-sql +sit application/x-stuffit +sitx application/x-stuffitx +srt application/x-subrip +sv4cpio application/x-sv4cpio +sv4crc application/x-sv4crc +t3 application/x-t3vm-image +gam application/x-tads +tar application/x-tar +tcl application/x-tcl +tex application/x-tex +tfm application/x-tex-tfm +texi application/x-texinfo +texinfo application/x-texinfo +obj application/x-tgif +ustar application/x-ustar +src application/x-wais-source +crt application/x-x509-ca-cert +der application/x-x509-ca-cert +fig application/x-xfig +xlf application/x-xliff+xml +xpi application/x-xpinstall +xz application/x-xz +z2 application/x-zmachine +z3 application/x-zmachine +z4 application/x-zmachine +z5 application/x-zmachine +z6 application/x-zmachine +z7 application/x-zmachine +z8 application/x-zmachine +z1 application/x-zmachine +xaml application/xaml+xml +xdf application/xcap-diff+xml +xenc application/xenc+xml +xht application/xhtml+xml +xhtml application/xhtml+xml +xsl application/xml +xml application/xml +dtd application/xml-dtd +xop application/xop+xml +xpl application/xproc+xml +xslt application/xslt+xml +xspf application/xspf+xml +xhvml application/xv+xml +xvml application/xv+xml +xvm application/xv+xml +mxml application/xv+xml +yang application/yang +yin application/yin+xml +zip application/zip +adp audio/adpcm +snd audio/basic +au audio/basic +midi audio/midi +kar audio/midi +rmi audio/midi +mid audio/midi +mp4a audio/mp4 +m4a audio/mp4 +mp2 audio/mpeg +mp2a audio/mpeg +mp3 audio/mpeg +m2a audio/mpeg +m3a audio/mpeg +mpga audio/mpeg +ogg audio/ogg +spx audio/ogg +oga audio/ogg +s3m audio/s3m +sil audio/silk +uvva audio/ +uva audio/ +eol audio/ +dra audio/vnd.dra +dts audio/vnd.dts +dtshd audio/vnd.dts.hd +lvp audio/vnd.lucent.voice +pya audio/ +ecelp4800 audio/vnd.nuera.ecelp4800 +ecelp7470 audio/vnd.nuera.ecelp7470 +ecelp9600 audio/vnd.nuera.ecelp9600 +rip audio/ +weba audio/webm +aac audio/aac +aiff audio/aiff +aifc audio/aiff +aif audio/aiff +caf audio/caf +flac audio/flac +mka audio/matroska +m3u audio/mpegurl +wax audio/x-ms-wax +wma audio/x-ms-wma +ra audio/x-pn-realaudio +ram audio/x-pn-realaudio +rmp audio/x-pn-realaudio-plugin +wav audio/wav +xm audio/xm +cdx chemical/x-cdx +cif chemical/x-cif +cmdf chemical/x-cmdf +cml chemical/x-cml +csml chemical/x-csml +xyz chemical/x-xyz +ttc font/collection +otf font/otf +ttf font/ttf +woff font/woff +woff2 font/woff2 +bmp image/bmp +cgm image/cgm +g3 image/g3fax +gif image/gif +ief image/ief +jpg image/jpeg +jpe image/jpeg +jpeg image/jpeg +ktx image/ktx +png image/png +btif image/prs.btif +sgi image/sgi +svgz image/svg+xml +svg image/svg+xml +tif image/tiff +tiff image/tiff +psd image/vnd.adobe.photoshop +uvvi image/vnd.dece.graphic +uvg image/vnd.dece.graphic +uvvg image/vnd.dece.graphic +uvi image/vnd.dece.graphic +djv image/vnd.djvu +djvu image/vnd.djvu +sub image/vnd.dvb.subtitle +dwg image/vnd.dwg +dxf image/vnd.dxf +fbs image/vnd.fastbidsheet +fpx image/vnd.fpx +fst image/vnd.fst +mmr image/ +rlc image/ +mdi image/ +wdp image/ +npx image/ +wbmp image/vnd.wap.wbmp +xif image/vnd.xiff +webp image/webp +3ds image/x-3ds +ras image/x-cmu-raster +cmx image/x-cmx +fhc image/x-freehand +fh4 image/x-freehand +fh5 image/x-freehand +fh7 image/x-freehand +fh image/x-freehand +ico image/x-icon +sid image/x-mrsid-image +pcx image/x-pcx +pct image/x-pict +pic image/x-pict +pnm image/x-portable-anymap +pbm image/x-portable-bitmap +pgm image/x-portable-graymap +ppm image/x-portable-pixmap +rgb image/x-rgb +tga image/x-tga +xbm image/x-xbitmap +xpm image/x-xpixmap +xwd image/x-xwindowdump +mime message/rfc822 +eml message/rfc822 +iges model/iges +igs model/iges +mesh model/mesh +silo model/mesh +msh model/mesh +dae model/vnd.collada+xml +dwf model/vnd.dwf +gdl model/vnd.gdl +gtw model/vnd.gtw +mts model/vnd.mts +vtu model/vnd.vtu +vrml model/vrml +wrl model/vrml +x3dbz model/x3d+binary +x3db model/x3d+binary +x3dvz model/x3d+vrml +x3dv model/x3d+vrml +x3dz model/x3d+xml +x3d model/x3d+xml +appcache text/cache-manifest +ifb text/calendar +ics text/calendar +css text/css +csv text/csv +htm text/html +html text/html +n3 text/n3 +text text/plain +conf text/plain +def text/plain +list text/plain +log text/plain +in text/plain +txt text/plain +dsc text/prs.lines.tag +rtx text/richtext +sgm text/sgml +sgml text/sgml +tsv text/tab-separated-values +tr text/troff +roff text/troff +man text/troff +me text/troff +ms text/troff +t text/troff +ttl text/turtle +uris text/uri-list +urls text/uri-list +uri text/uri-list +vcard text/vcard +curl text/vnd.curl +dcurl text/vnd.curl.dcurl +mcurl text/vnd.curl.mcurl +scurl text/vnd.curl.scurl +sub text/vnd.dvb.subtitle +fly text/ +flx text/vnd.fmi.flexstor +gv text/vnd.graphviz +3dml text/vnd.in3d.3dml +spot text/ +jad text/ +wml text/vnd.wap.wml +wmls text/vnd.wap.wmlscript +asm text/x-asm +s text/x-asm +cc text/x-c +cxx text/x-c +cpp text/x-c +h text/x-c +hh text/x-c +dic text/x-c +c text/x-c +for text/x-fortran +f77 text/x-fortran +f90 text/x-fortran +f text/x-fortran +java text/x-java-source +nfo text/x-nfo +opml text/x-opml +pas text/x-pascal +p text/x-pascal +etx text/x-setext +sfv text/x-sfv +uu text/x-uuencode +vcs text/x-vcalendar +vcf text/x-vcard +3gp video/3gpp +3g2 video/3gpp2 +h261 video/h261 +h263 video/h263 +h264 video/h264 +jpgv video/jpeg +jpgm video/jpm +jpm video/jpm +mjp2 video/mj2 +mj2 video/mj2 +mp4v video/mp4 +mpg4 video/mp4 +mp4 video/mp4 +mpg video/mpeg +mpe video/mpeg +m1v video/mpeg +m2v video/mpeg +mpeg video/mpeg +ogv video/ogg +mov video/quicktime +qt video/quicktime +uvvh video/vnd.dece.hd +uvh video/vnd.dece.hd +uvvm video/ +uvm video/ +uvvp video/vnd.dece.pd +uvp video/vnd.dece.pd +uvvs video/ +uvs video/ +uvvv video/ +uvv video/ +dvb video/vnd.dvb.file +fvt video/vnd.fvt +m4u video/vnd.mpegurl +mxu video/vnd.mpegurl +pyv video/ +uvvu video/vnd.uvvu.mp4 +uvu video/vnd.uvvu.mp4 +viv video/ +webm video/webm +f4v video/x-f4v +fli video/x-fli +flv video/x-flv +m4v video/x-m4v +mk3d video/x-matroska +mks video/x-matroska +mkv video/x-matroska +mng video/x-mng +asx video/x-ms-asf +asf video/x-ms-asf +vob video/x-ms-vob +wm video/x-ms-wm +wmv video/x-ms-wmv +wmx video/x-ms-wmx +wvx video/x-ms-wvx +avi video/x-msvideo +movie video/x-sgi-movie +smv video/x-smv +ice x-conference/x-cooltalk diff --git a/etc/pack/libgit2/build b/etc/pack/libgit2/build @@ -1,19 +1,20 @@ #!/bin/sh -ex -cp "$DEF/features.h" "$SOURCE/include/git2/sys/" +cp "${DEF}/features.h" include/git2/sys -rm -f "$SOURCE/src/hash/hash_generic.c" -rm -f "$SOURCE/src/hash/hash_win32.c" -rm -fR "$SOURCE/src/win32/" +rm -f src/hash/hash_generic.c +rm -f src/hash/hash_win32.c +rm -fR src/win32 -cd src +(cd src + for x in *.c */*.c */*/*.c ../deps/http-parser/*.c; do + cc -c -fPIC -I. -I../include -I../deps/http-parser "${x}" + done -cc -c -fPIC \ - -I./ -I"/opt/libressl/include" -I../include/ -I../deps/http-parser/ \ - ./*.c ./*/*.c ./*/*/*.c ../deps/http-parser/*.c -cc -shared -o *.o -ar -rcs libgit2.a *.o + cc -shared -o *.o + ar -rcs libgit2.a *.o +) -mkdir -p "$PREFIX/lib/" -cp libgit2.a "$PREFIX//lib/" -cp -R "$SOURCE/include/" "$PREFIX/" +mkdir -p "$PREFIX/lib" +cp src/ src/libgit2.a "${PREFIX}/lib" +cp -R include "$PREFIX" diff --git a/etc/pack/stagit-gopher/ b/etc/pack/stagit-gopher/ @@ -5,25 +5,14 @@ PREFIX = ${PREFIX} MANPREFIX = ${PREFIX}/share/man # compiler and linker -#CC = cc - -GITINC = $(libgit2)/include -GITLIB = $(libgit2)/lib +CC = cc # includes and libs -INCS = -I${GITINC} -LIBS = -L${GITLIB} -lgit2 -lz -lssl -lpthread - -# debug -#CFLAGS = -fstack-protector-all -O0 -g -std=c99 -Wall -Wextra -pedantic ${INCS} -#LDFLAGS = ${LIBS} - -# optimized -CFLAGS = -O2 -std=c99 ${INCS} -LDFLAGS = -s ${LIBS} +INCS = -I${libgit2}/include -I${libressl}/include -I${libz}/include +LIBS = -L${libgit2}/lib -L${libressl}/lib -L${libz}/lib -lssl -lgit2 -lssl -lz -lssl -lpthread -lssl -lcrypto # optimized static -#CFLAGS = -static -O2 -std=c99 ${INCS} -#LDFLAGS = -static -s ${LIBS} +CFLAGS = -static -O2 -std=c99 ${INCS} +LDFLAGS = -static -s ${LIBS} CPPFLAGS = -D_XOPEN_SOURCE=700 -D_DEFAULT_SOURCE -D_BSD_SOURCE ${INCS} diff --git a/etc/pack/stagit-gopher/dependencies/libgit2 b/etc/pack/stagit-gopher/dependencies/libgit2 @@ -0,0 +1 @@ +0.27.2 diff --git a/etc/pack/stagit-gopher/dependencies/libressl b/etc/pack/stagit-gopher/dependencies/libressl @@ -0,0 +1 @@ +2.8.2 diff --git a/etc/pack/stagit/ b/etc/pack/stagit/ @@ -5,22 +5,11 @@ PREFIX = ${PREFIX} MANPREFIX = ${PREFIX}/share/man # compiler and linker -#CC = cc - -GITINC = $(libgit2)/include -GITLIB = $(libgit2)/lib +CC = cc # includes and libs -INCS = -I${GITINC} -LIBS = -L${GITLIB} -lgit2 -lz -lssl -lpthread - -# debug -#CFLAGS = -fstack-protector-all -O0 -g -std=c99 -Wall -Wextra -pedantic ${INCS} -#LDFLAGS = ${LIBS} - -# optimized -#CFLAGS = -O2 -std=c99 ${INCS} -#LDFLAGS = -s ${LIBS} +INCS = -I${libgit2}/include -I${libressl}/include -I${libz}/include +LIBS = -L${libgit2}/lib -L${libressl}/lib -L${libz}/lib -lssl -lgit2 -lssl -lz -lssl -lpthread -lssl -lcrypto # optimized static CFLAGS = -static -O2 -std=c99 ${INCS} diff --git a/etc/pack/stagit/dependencies/libgit2 b/etc/pack/stagit/dependencies/libgit2 @@ -0,0 +1 @@ +../../libgit2/version+ \ No newline at end of file diff --git a/etc/pack/stagit/dependencies/libressl b/etc/pack/stagit/dependencies/libressl @@ -0,0 +1 @@ +../../libressl/version+ \ No newline at end of file diff --git a/etc/s6/qmail-send/x/env/GROUP b/etc/s6/qmail-send/x/env/GROUP @@ -0,0 +1 @@ +sqmail diff --git a/etc/s6/qmail-send/x/env/USER b/etc/s6/qmail-send/x/env/USER @@ -0,0 +1 @@ +root diff --git a/etc/s6/qmail-send/x/setup b/etc/s6/qmail-send/x/setup @@ -1,6 +1,9 @@ #!/usr/bin/env execlineb - s6-envdir env -importas USER USER + +multisubstitute { + importas USER USER + importas GROUP GROUP +} if { s6-hiercopy conf /var/qmail } -chgrp -R ${USER} /var/qmail +chgrp -R ${USER}:${GROUP} /var/qmail