Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(docs): examples #177

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 6 additions & 27 deletions example/dinghyfile
Original file line number Diff line number Diff line change
@@ -1,37 +1,16 @@
{
"application": "dinghy",
"variables": {
"WaitTime1": 60,
"WaitTime2": 60,
"limit": 1
},
"application": "test-dinghy",
"pipelines": [
{
"application": "dinghy",
"application": "test-dinghy",
"keepWaitingPipelines": false,
"limitConcurrent": {{ variable limit }},
"name": "Simple",
"limitConcurrent": true,
"name": "test",
"stages": [
{{ module "./wait.stage.module" {Name: "waitTime", Value: 10} }}
{{ module "wait.stage.module" }}
],
"triggers": []
},
{{ module "./simple.pipeline.module" }}
{{ module "simple.pipeline.module" }}
]
}


type Variable struct {
Name string
Value interface{}
}

func module(name string, vars ...Variable) {

}

/*



*/
41 changes: 26 additions & 15 deletions example/github_payload.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,28 @@
{
"commits": [
{
"id": "EXAMPLE",
"added": [],
"modified": ["dinghyfile"]
}
],
"repository": {
"name": "dinghy-plank-integration",
"organization": "armory-io",
"owner": {
"login": "dotdotdotpaul"
}
},
"ref": "refs/heads/master"
"ref": "refs/heads/master",
"repository": {
"name": "dinghy-plank-integration",
"organization": "armory-io",
"full_name": "armory-io/dinghy-plank-integration",
"private": true,
"owner": {
"name": "dotdotdotpaul",
"login": "dotdotdotpaul"
}
},
"pusher": {
"name": "dotdotdotpaul"
},
"organization": {
"login": "armory-io"
},
"commits": [
{
"id": "example",
"tree_id": "example",
"added": [],
"removed": [],
"modified": ["dinghyfile"]
}
]
}
8 changes: 4 additions & 4 deletions example/simple.pipeline.module
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"application": "dinghy",
"application": "test-dinghy",
"keepWaitingPipelines": false,
"limitConcurrent": true,
"name": "Simple",
"name": "test pipeline module",
"stages": [
{{ module wait.stage.module }}
{{ module "wait.stage.module" "waitTime" 200 }}
],
"triggers": []
}
}
12 changes: 6 additions & 6 deletions example/wait.stage.module
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "Wait",
"refId": "1",
"requisiteStageRefIds": [],
"type": "wait",
"waitTime": 120
}
"name": "{{ var "name" ?: "defaultname" }}",
"refId": "1",
"requisiteStageRefIds": [],
"type": "wait",
"waitTime": {{ var "waitTime" ?: 10 }}
}