Skip to content

Commit

Permalink
Add CI distributable building
Browse files Browse the repository at this point in the history
  • Loading branch information
wyozi committed Mar 19, 2019
1 parent a42ed28 commit 2f57c6a
Show file tree
Hide file tree
Showing 6 changed files with 31 additions and 1,360 deletions.
21 changes: 21 additions & 0 deletions .github/main.workflow
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
workflow "Build" {
on = "release"
resolves = ["Upload .lua", "Upload .min.lua"]
}

action "Build distributable" {
uses = "./builder"
}

action "Upload .lua" {
uses = "JasonEtco/upload-to-release@master"
args = "dist/medialib.lua"
secrets = ["GITHUB_TOKEN"]
needs = ["Build distributable"]
}
action "Upload .min.lua" {
uses = "JasonEtco/upload-to-release@master"
args = "dist/medialib.min.lua"
secrets = ["GITHUB_TOKEN"]
needs = ["Build distributable"]
}
10 changes: 10 additions & 0 deletions builder/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM node:alpine

RUN apk add --no-cache git

RUN mkdir /builder
COPY build.js /builder
COPY package.json /builder
RUN cd /builder && npm install

CMD [ "sh", "-c", "node /builder/build.js --no-git build"]
2 changes: 0 additions & 2 deletions builder/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ fi
git add dist/*.lua
*/

process.chdir(".."); // We want to be at the addon root

var Q = require("q");

var buildNoGit = false;
Expand Down
Empty file added dist/.gitkeep
Empty file.
Loading

0 comments on commit 2f57c6a

Please sign in to comment.