Baphomet is the dedicated bot for nulloctet matrix
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

87 lines
2.6 KiB

---
resources:
- name: baphomet-js-git
type: git
icon: git
source:
uri: ssh://git@git.nulloctet.com:8437/warricksothr/basphomet-js.git
private_key: |
((pull_key))
jobs:
- name: test
public: true
plan:
- get: baphomet-js-git
trigger: true
- task: run-tests
config:
platform: linux
image_resource:
type: registry-image
source: { repository: node, tag: "13" }
inputs:
- name: baphomet-js-git
run:
path: /bin/sh
args:
- -c
- |
echo "Node Version: $(node --version)"
echo "NPM Version: $(npm --version)"
cd baphomet-js-git
npm install
npm test
- name: package
public: true
plan:
- get: baphomet-js-git
passed: [test]
trigger: true
- task: capture-version
config:
platform: linux
image_resource:
type: registry-image
source: { repository: bitnami/git, tag: "2-debian-9" }
inputs:
- name: baphomet-js-git
outputs:
- name: baphomet-js-version
run:
path: /bin/sh
args:
- -c
- |
cd baphomet-js-git
echo "$(git describe --tags)-$(git rev-parse HEAD)-$(date --rfc-3339=seconds)" > ../baphomet-js-version/build.info
echo "$(git describe --tags)-$(git rev-parse HEAD)" > ../baphomet-js-version/version.info
cat ../baphomet-js-version/build.info
- task: package
config:
platform: linux
image_resource:
type: registry-image
source: { repository: debian, tag: "stretch-slim" }
inputs:
- name: baphomet-js-git
- name: baphomet-js-version
outputs:
- name: package
run:
path: /bin/sh
args:
- -c
- |
mkdir tmp
cd tmp
cp ../baphomet-js-version/version.info .
cp ../baphomet-js-version/build.info .
cp ../baphomet-js-git/package*.json .
cp ../baphomet-js-git/index.js .
cp -r ../baphomet-js-git/assets .
cp -r ../baphomet-js-git/bot .
cp -r ../baphomet-js-git/data .
cp ../baphomet-js-git/README.md .
cp ../baphomet-js-git/LICENSE.md .
tar -zcvf ../package/baphomet-js-$(cat version.info).tgz ./*