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

Test #4

Open
wants to merge 10 commits 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
7 changes: 6 additions & 1 deletion .github/workflows/simple.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,20 @@
name: shell commands
on : [push]
on : [pull_request]

jobs:
run-shell-command:

runs-on: ubuntu-latest
env:
working : ${{ github.base_ref }}
steps:
- name: echo string
run : echo "hello world"
- name : multiline script
run : |
node -v
npm -v
echo $working
- name : python command
run : |
import platform
Expand Down
File renamed without changes.
13 changes: 13 additions & 0 deletions all-work-flows/container.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name : run docker container in work flow
#here all our steps of the job will run in container instead of VM directly
on : [push]
jobs:
node-docker:
runs-on: ubuntu-latest
container:
image: node:13.5.0-alpine3.10
steps:
- name : log node version
run : |
node -v
cat /etc/os-release
30 changes: 30 additions & 0 deletions all-work-flows/env.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: env virables workflow
on : push
env:
WF_ENV : Available to all jobs
jobs:
log-env:
runs-on: ubuntu-latest
env :
JOB_ENV : Availabe in log env job
steps:
- name : Log env variables
env:
STEP_ENV : Available only in step
run: |
echo "WF_ENV:${WF_ENV}"
echo "JOB_ENV:${JOB_ENV}"
echo "STEP_ENV:${STEP_ENV}"
- name : log 2 step
run : |
echo "WF_ENV:${WF_ENV}"
echo "JOB_ENV:${JOB_ENV}"
echo "STEP_ENV:${STEP_ENV}"
log2-env:
runs-on : ubuntu-latest
steps:
- name: test access envs
run : |
echo "WF_ENV:${WF_ENV}"
echo "JOB_ENV:${JOB_ENV}"
echo "STEP_ENV:${STEP_ENV}"
32 changes: 32 additions & 0 deletions all-work-flows/matrix.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name : matrix workflow
on : [pull_request]
jobs:
node-version:
strategy:
matrix:
node_version: [6,7,8]
os_type: [ubuntu-latest, windows-latest]
exclude:
- os_type: ubuntu-latest
node_version: 6
- os_type: windows-latest
node_version: 8
include:
- os_type : ubuntu-latest
node_version: 7
is_ubuntu: "true"

runs-on : ${{matrix.os_type}}
env:
IS_UBUNTU_7: ${{matrix.is_ubuntu}}
steps :
- name: node version original
run : node -v
- name : changing node version
uses : actions/setup-node@v2
with :
node-version: ${{matrix.node_version}}
- name: node version after modification
run : |
node -v
echo "IS_UBUNTU_7:"$IS_UBUNTU_7
Empty file added test
Empty file.