summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-07-21 14:40:50 (EDT)
committer P. J. McDermott <pjm@nac.net>2012-07-21 14:40:50 (EDT)
commit179d843c896f6ff55e324b76d1cb754c65297f5d (patch)
treee532630b027fc9322115c36a505009b474ac8bd1
parent66e15cc7256ff7cd438386b053da0aa23d4da51a (diff)
downloaddeb-179d843c896f6ff55e324b76d1cb754c65297f5d.zip
deb-179d843c896f6ff55e324b76d1cb754c65297f5d.tar.gz
deb-179d843c896f6ff55e324b76d1cb754c65297f5d.tar.bz2
Implement "push" command.
-rwxr-xr-xsrc/deb.sh18
1 files changed, 17 insertions, 1 deletions
diff --git a/src/deb.sh b/src/deb.sh
index e6269fb..40defaf 100755
--- a/src/deb.sh
+++ b/src/deb.sh
@@ -19,7 +19,7 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-COMMANDS='init config update download edit builddsc'
+COMMANDS='init config update download edit builddsc push'
CONFIG_NAMES='mirror distribution component remote buildcmd'
main()
@@ -348,4 +348,20 @@ EOF
> "${DEB_TREE}/pkgs/${pkg}/${pkg}.debdiff"
}
+cmd_push()
+{
+ find_deb_dir
+ config_load
+
+ if [ ${#} -ne 0 ]; then
+ cat >&2 <<EOF
+Usage: ${SCRIPT_NAME} ${COMMAND_NAME}
+EOF
+ exit 1
+ fi
+
+ rsync -az --stats "${DEB_TREE}/pkgs/" "${CONFIG_remote}/pkgs/"
+ rsync -az --stats "${DEB_TREE}/builds/" "${CONFIG_remote}/builds/"
+}
+
main ${@}