diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..c646353 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,50 @@ +name: Test Workflow + +on: + # Triggers the workflow when called from organization repository + workflow_call: + inputs: + test_param: + required: false + default: 'value' + type: string + +jobs: + release: + # The type of runner that the job will run on + runs-on: ubuntu-20.04 + + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Fetch all tags + run: | + git config --global user.email "actions@github.com" + git config --global user.name "Github actions" + git fetch --tags --unshallow --prune + + - name: Publish release + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + latest_tag=v${{github.run_number}} + gh release create $latest_tag --generate-notes + + publish: + # The type of runner that the job will run on + runs-on: ubuntu-20.04 + + steps: + # Checkout Project + - name: Checkout + uses: actions/checkout@v2 + with: + ref: ${{ github.ref }} + + - name: Project + run: | + pwd + ls + cd .. + ls \ No newline at end of file diff --git a/.gitignore b/.gitignore index 0e13eeb..c37f338 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ buildNumber.properties .mvn/timing.properties # https://github.com/takari/maven-wrapper#usage-without-binary-jar .mvn/wrapper/maven-wrapper.jar +.idea diff --git a/etc/docs/example.txt b/etc/docs/example.txt new file mode 100644 index 0000000..0a1d027 --- /dev/null +++ b/etc/docs/example.txt @@ -0,0 +1,4 @@ +TEST FILE +- 1 +- 2 +- 3 \ No newline at end of file diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..1ba4162 --- /dev/null +++ b/pom.xml @@ -0,0 +1,12 @@ + + + 4.0.0 + + am-reusable-workflows + reusable_workflows + 1.0-SNAPSHOT + + + \ No newline at end of file