Archived
1
0

use gx for package management

This commit is contained in:
Jeff Becker 2016-04-18 08:40:01 -04:00
parent 8d83e4dbaf
commit 8ac1c210f2
No known key found for this signature in database
GPG Key ID: AB950234D6EA286B
3 changed files with 31 additions and 4 deletions

View File

@ -16,18 +16,39 @@ for arg in $@ ; do
esac esac
done done
rev="QmSLsdX9BQ1f9sBeuMeLnrmFEWQiNJG9nRmgi4Pua2Ui3y"
_next=""
# check for build flags # check for build flags
for arg in $@ ; do for arg in $@ ; do
case $arg in case $arg in
"--disable-redis") "--disable-redis")
tags="$tags -tags disable_redis" tags="$tags -tags disable_redis"
;; ;;
"--revision")
_next="rev"
;;
"--revision=*")
rev=$(echo $arg | cut -d'=' -f2)
;;
*)
if [ "x$_next" == "xrev" ] ; then
rev="$arg"
fi
esac esac
done done
if [ "x$rev" == "x" ] ; then
echo "revision not specified"
exit 1
fi
cd $root cd $root
export GOPATH=$root/go export GOPATH=$root/go
mkdir -p $GOPATH mkdir -p $GOPATH
go get -v -u $tags github.com/majestrate/srndv2 echo "obtaining gx"
cp -a $GOPATH/bin/srndv2 $root go get -v github.com/whyrusleeping/gx-go
gx install --global
go get -v gx/ipfs/$rev/srndv2
cp $GOPATH/bin/srndv2 $root
echo "Built" echo "Built"

View File

@ -3,6 +3,12 @@
"author": "jeff", "author": "jeff",
"version": "0.0.0", "version": "0.0.0",
"gxDependencies": [ "gxDependencies": [
{
"author": "jeff",
"name": "srndv2",
"hash": "QmSLsdX9BQ1f9sBeuMeLnrmFEWQiNJG9nRmgi4Pua2Ui3y",
"version": "0.0.0"
}
], ],
"language": "go", "language": "go",
"issues_url": "https://github.com/majestrate/nntpchan", "issues_url": "https://github.com/majestrate/nntpchan",

View File

@ -2,7 +2,7 @@ package main
import ( import (
"fmt" "fmt"
"github.com/majestrate/srndv2/src/srnd" "gx/ipfs/QmSLsdX9BQ1f9sBeuMeLnrmFEWQiNJG9nRmgi4Pua2Ui3y/srndv2/src/srnd"
"log" "log"
"os" "os"
"os/signal" "os/signal"