1 ! Copyright (C) 2008, 2010 Eduardo Cavazos, Slava Pestov.
2 ! See https://factorcode.org/license.txt for BSD license.
3 USING: io.directories kernel make mason.common mason.config
4 mason.platform namespaces sequences ;
5 IN: mason.release.branch
7 : branch-name ( -- string ) "clean-" platform append ;
9 : refspec ( -- string ) "master:" branch-name append ;
11 : push-to-clean-branch-cmd ( -- args )
13 { "git" "push" "-f" } %
15 branch-username get % "@" %
16 branch-host get % ":" %
17 branch-directory get %
22 : push-to-clean-branch ( -- )
23 5 [ push-to-clean-branch-cmd short-running-process ] retry ;
25 : upload-clean-image-cmd ( -- args )
28 target-boot-image-name ,
30 image-username get % "@" %
31 image-host get % ":" %
32 image-directory get % "/" %
37 : upload-clean-image ( -- )
38 5 [ upload-clean-image-cmd short-running-process ] retry ;
40 : update-clean-branch ( -- )
41 update-clean-branch? get [