forked from bestpractical/sd
-
Notifications
You must be signed in to change notification settings - Fork 1
/
shipwright-package
59 lines (53 loc) · 2.23 KB
/
shipwright-package
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
export TODAY=`date +%Y-%m-%d`
export REPO=${HOME}/shipwright-sd-${TODAY}.git/
#export REPO=/tmp/shipwright-sd-${TODAY}.git/
export GIT_PATH="git:file://$REPO"
export MIN_PERL=5.008006
export SKIP="--skip=Pod::Simple,Module::Signature,Test::Pod,Test::Pod::Coverage,Test::Distribution,Pod::Readme,Archive::Tar,HTML::Lint,Prophet,Encode,Date::Calc,Test::Cukes,Quantum::Superpositions,Test::Memory::Cycle,Text::Greeking,Test::HTTP::Server::Simple,Test::WWW::Mechanize,Module::Build,Test::Warn,Test::MockTime,Test::MockModule,Test::MockObject,Test::Warn"
export IMPORT="shipwright import --min-perl-version=$MIN_PERL $SKIP -r $GIT_PATH --log-file - --log-level debug"
rm -rf $REPO
shipwright create -r $GIT_PATH
# Optional deps we still want
$IMPORT \
cpan:Scalar::Util \
cpan:Template::Declare \
cpan:HTTP::Server::Simple \
cpan:File::ShareDir \
cpan:DBI \
cpan:DBD::SQLite \
cpan:Net::GitHub \
cpan:Term::ReadLine::Perl \
cpan:JSON::XS \
cpan:Net::Bonjour \
cpan:Term::ReadKey \
cpan:Config::GitLike \
git:git+ssh://fsck.com/git/prophet.git \
cpan:RT::Client::REST \
cpan:Email::Address \
cpan:Net::Jifty \
cpan:Net::Trac \
cpan:Net::Google::Code \
git:git+ssh://fsck.com/git/sd.git
cd /tmp
#shipwright update -r $GIT_PATH cpan-Module-Build --add-deps cpan-Pod-Simple
#shipwright update -r $GIT_PATH cpan-IO-Compress-Base --add-deps cpan-Scalar-List-Utils
shipwright update -r $GIT_PATH prophet.git --add-deps cpan-Term-ReadLine-Perl,cpan-TermReadKey,cpan-DBD-SQLite,cpan-File-ShareDir,cpan-HTTP-Server-Simple,cpan-JSON-XS,cpan-Config::GitLike
shipwright update -r $GIT_PATH sd.git --add-deps prophet.git,cpan-Net-Bonjour,cpan-Email-Address,cpan-Net-Trac,cpan-RT-Client-REST,cpan-Net-Google-Code
shipwright maintain -r $GIT_PATH --update-order
cd /tmp
git clone file://${REPO} hack-$$
cd hack-$$/scripts/cpan-DateTime-Format-Natural
perl -pi -e s'/Build test/Build/g' build
git config push.default matching
git commit -m 'Made DTFN not run its tests which add a slew of deps' build
git push
cd /tmp/
rm -rf hack-$$
git clone file://$REPO /tmp/sdex-$$
cd /tmp/sdex-$$
echo "# one argument per line
--skip-man-pages
--skip-test
--install-base=~/sd
" > __default_builder_options
./bin/shipwright-utility --generate-tar-file /tmp/sd-image-${TODAY}.bin