1. 20 Nov, 2021 1 commit
    • Morten Linderud's avatar
      cronjobs/ftpdir-cleanup: Support DEBUGPKGPOOL · a8f8ee96
      Morten Linderud authored
      This implementation is probably the easiest one and/or cheap. After
      building a list of all packages in the repositories we filter the lists
      into two separate working lists. One for normal packages and one for
      debug packages.
      The only issue is that we can encounter globs with no matching cleanup
      lists, like when running ftpdir-cleanup after the debug package changes
      has been introduced, but before deploying new repositories. We guard
      against this by ensuring we have found debug packages, and normal
      packages, before checking the working lists.
      This introduces some duplicated code but should be fine. Rest of the
      logic is mirrored between the two package pools.
      Signed-off-by: Morten Linderud's avatarMorten Linderud <morten@linderud.pw>
  2. 08 Apr, 2018 2 commits
    • Luke Shumaker's avatar
      Consistently use "$(dirname "$(readlink -e "$0")")" · 0cf2ac49
      Luke Shumaker authored and Eli Schwartz's avatar Eli Schwartz committed
      This does correct handling of
       - executing a program by symlink
       - any weird characters in the full path
       - I'm sure there's another case I thought about when I originally did
    • Luke Shumaker's avatar
      Fixup quoting around variables, especially arrays · 5b4b19cd
      Luke Shumaker authored and Eli Schwartz's avatar Eli Schwartz committed
      Search for unquoted variables using the command:
          grep -Prn --exclude-dir=.git '(?<!["=]|\[\[ |\[\[ -[zn] )\$(?!{?#|\(|\? )'
      and ignore a bunch of false positives.
      You may verify that the only differences between the lines removed and
      lines added are double-quotes:
              diff -u \
                <(git show|sed -n 's/^-//p'|grep -v '^-- a/'|sed 's/"//g') \
                <(git show|sed -n 's/^+//p'|grep -v '^++ b/'|sed 's/"//g')
  3. 20 Mar, 2018 1 commit
  4. 16 Mar, 2018 1 commit
    • Luke Shumaker's avatar
      Update messages to make fuller use of printf formatters · 33aae318
      Luke Shumaker authored and Eli Schwartz's avatar Eli Schwartz committed
      These are things that were (IMO) missed in 5afac1ed.  I found them using:
          git grep -E '(plain|msg|msg2|warning|error|die) "[^"]*\$'
      I went a little above-and-beyond for escaping strings for the error
      messages in db-functions' arch_repo_add and arch_repo_remove.  The
      code should explain itself, but I wanted to point it out, as it's more than
      the usual "slap %s in there, and move the ${...} to the right".
  5. 20 Feb, 2018 3 commits
    • Eli Schwartz's avatar
      ftpdir-cleanup,sourceballs: replace external find command with bash globbing · c82f4372
      Eli Schwartz authored
      This fully removes the use of find from the codebase, leads to a
      micro-optimization in a couple cases, and ensures that $PKGEXT is
      consistently treated as a shell globbing character (which is important
      because it is used as one).
      Of the eight instances in these files:
      - One was unnecessary as `cat` can natively consume all files passed to
        it and no directory traversal was in use.
      - Two were unnecessary as they were hardcoded to read a single file....
      - Another four were only being used to strip leading directory paths,
        and can be replaced by globstar and ${filepath##*/}
      - The final two were checking the modification time of the files, and
        can be replaced with touch(1) and [[ -nt ]]. Although this introduces
        an additional temporary file, this is not such a big deal.
    • Eli Schwartz's avatar
      Fix overloading PKGEXT to mean two things. · 07e6a91d
      Eli Schwartz authored
      PKGEXT is a makepkg variable referring to a fixed filename suffix, but
      we were also using it to mean a bash glob referring to candidate
      filenames. This is wrong, so rename it to PKGEXTS which is more
      descriptive of its purpose.
      Exclude the testsuite from this change, as the testsuite actually uses
      PKGEXT for its intended purpose. Fix the testsuite to consistently use
      PKGEXT, as it hardcoded the file extension in several cases, and pin
      its value to .pkg.tar.xz
    • Eli Schwartz's avatar
      Use even more bashisms. · b45650c3
      Eli Schwartz authored
      Catch some cases that were missed in the previous run.
  6. 15 Feb, 2018 1 commit
    • Eli Schwartz's avatar
      Update messages to make full use of printf formatters · 5afac1ed
      Eli Schwartz authored
      libmakepkg messaging functions provide automatic access to gettext
      (which we do not currently make use of) in addition to cleanly
      separating data from message strings.
      In order for this to work properly, pass argv correctly from die() to
      libmakepkg's error()
  7. 01 Nov, 2014 1 commit
  8. 02 Nov, 2013 1 commit
  9. 20 Jan, 2013 1 commit
  10. 10 Jun, 2012 1 commit
  11. 29 Apr, 2012 1 commit
  12. 19 Dec, 2011 1 commit
  13. 02 Apr, 2011 1 commit
  14. 30 Jan, 2011 1 commit
  15. 18 Dec, 2010 2 commits
  16. 25 Nov, 2010 1 commit
  17. 11 Sep, 2010 1 commit
    • Pierre Schmitz's avatar
      Use local config instead of guessing by hostname · f121126f
      Pierre Schmitz authored
      Using the hostname to decide which repos to use is not releiable and hard to test.
      Instead use config.local to configure these.
      config files for sigurd and gerolde were added which can be copied or symlinked to config.local
      on the specific host.
  18. 18 Aug, 2010 2 commits
    • Pierre Schmitz's avatar
      fix typo · b48b6b62
      Pierre Schmitz authored
    • Pierre Schmitz's avatar
      Rewrite ftpdir-cleanup · 683db123
      Pierre Schmitz authored
      * runtime reduced to < 1 second
      * uses file lists and the comm command
      * searches for missing packages
      * removes empty legacy directories like extra/os/any
  19. 13 Aug, 2010 1 commit
  20. 10 Aug, 2010 1 commit
    • Pierre Schmitz's avatar
      Use more consitent naming for package pool · af4f8680
      Pierre Schmitz authored
      There are no longer architecture-specific subdirs and the structure was switch to this:
      └── pool
          ├── community
          └── packages
      packages contains all packages from core, extra and testing; this naming is in sync with the svn repo naming:
      svn-packages and svn-community
  21. 08 Aug, 2010 1 commit
    • Pierre Schmitz's avatar
      Move common function to db-functions · 9eb1cd7b
      Pierre Schmitz authored
      db-functions now sets an individual $WORKDIR and implements trap functinos that
      remove locks on exit or error. There are new functions to lock and unlock the running script.
      misc-scripts/ftpdir-cleanup was renamed to ftpdir-cleanup-repo as the cron-job had the same name.
      Script names have to be unique when using db-functions.
  22. 07 Aug, 2010 1 commit
  23. 20 Jun, 2010 2 commits
  24. 03 May, 2010 1 commit
  25. 28 Apr, 2010 3 commits
  26. 13 Sep, 2009 1 commit
  27. 18 Aug, 2009 1 commit
  28. 03 Aug, 2009 1 commit
  29. 21 Jul, 2009 1 commit
    • Francois Charette's avatar
      Refactor ftpdir-cleanup to handle all arches · 820452a9
      Francois Charette authored
      This may look like a rather large patch, but the changes are mostly a
      reshuffling of the code to loop over all arches first, and then handle
      the arch-indep packages. The cronjob has been changed accordingly.
      Added new category DELETESYMLINKS, which are deleted instead of being
      moved to package-cleanup. I have also fixed the arch-specific issue
      with the ftppath, using parameters in config instead.
      Signed-off-by: default avatarAaron Griffin <aaronmgriffin@gmail.com>
  30. 20 Jul, 2009 1 commit
  31. 17 Jul, 2009 2 commits