[DRE-commits] [pkg-ruby-extras] 01/01: Add script to cleanup PET data

zeha at debian.org zeha at debian.org
Fri Mar 25 20:25:15 UTC 2016


This is an automated email from the git hooks/post-receive script.

zeha pushed a commit to branch master
in repository pkg-ruby-extras.

commit 26746576a17e004236ef8ebf6b418fe24ec185ae
Author: Christian Hofstaedtler <zeha at debian.org>
Date:   Fri Mar 25 20:25:09 2016 +0000

    Add script to cleanup PET data
---
 pet-cleanup | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/pet-cleanup b/pet-cleanup
new file mode 100755
index 0000000..ab62b27
--- /dev/null
+++ b/pet-cleanup
@@ -0,0 +1,18 @@
+#!/usr/bin/ruby -w
+# 1) Copy this file to git.debian.org
+# 2) cd /srv/home/groups/pet/htdocs/pet2-data/pkg-ruby-extras
+# 3) run ~/pet-cleanup
+# 4) check the .cleansed output file
+# 5) cp git-pkg-ruby-extras.json.cleansed git-pkg-ruby-extras.json
+# 6) /home/groups/pet/PET2/pkg-ruby-extras/pet-git-helper update-all
+
+require 'json'
+
+ROOT = '/git/pkg-ruby-extras'
+
+data = JSON.load File.read('git-pkg-ruby-extras.json')
+data.each do |pkgname|
+  data.delete pkgname if not File.exist?("#{ROOT}/#{pkgname}.git")
+end
+
+File.write('git-pkg-ruby-extras.json.cleansed', JSON.dump(data))

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/pkg-ruby-extras.git



More information about the Pkg-ruby-extras-commits mailing list