Refs #11. Fixed warnings. "Compile" GitHub action will now use EA3133… #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: Compile | |
# yamllint disable-line rule:truthy | |
on: | |
pull_request: | |
branches: | |
- 'master' | |
- 'dev*' | |
paths-ignore: | |
- '*.md' | |
- '.git*' | |
push: | |
branches: | |
- 'master' | |
- 'dev*' | |
paths-ignore: | |
- '*.md' | |
- '.git*' | |
jobs: | |
GetList: | |
outputs: | |
filelist: ${{ steps.get-files.outputs.filelist }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set output with list of files | |
id: get-files | |
run: | | |
import glob, json, os | |
fghout = os.environ["GITHUB_OUTPUT"] | |
files = glob.glob("**/*.mq?", recursive=True) | |
filelist = "filelist={}".format(json.dumps(files)) | |
with open(fghout, "a") as fd: | |
fd.write(filelist) | |
shell: python | |
- name: Display outputs | |
run: echo "${{ toJson(steps.get-files.outputs) }}" | |
Compile: | |
defaults: | |
run: | |
shell: powershell | |
needs: [GetList] | |
runs-on: windows-latest | |
strategy: | |
matrix: | |
file: ${{ fromJson(needs.GetList.outputs.filelist) }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/checkout@v3 | |
with: | |
path: Include/EA31337-classes | |
ref: v3.000-dev | |
repository: EA31337/EA31337-classes | |
- name: Compile (build 2361) | |
uses: fx31337/mql-compile-action@master | |
with: | |
include: . | |
init-platform: true | |
mt-version: 5.0.0.2361 | |
path: ${{ matrix.file }} | |
verbose: true | |
- name: Compile (build 2515) | |
if: endsWith(matrix.file, '.mq5') | |
uses: fx31337/mql-compile-action@master | |
with: | |
include: . | |
init-platform: true | |
mt-version: 5.0.0.2515 | |
path: ${{ matrix.file }} | |
verbose: true | |
- name: List compiled files | |
run: '(Get-ChildItem -Recurse -Path . -Include *.ex[45]).fullname' | |
- run: Get-Location | |
- name: Upload indicator artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: Indicators-other | |
path: '**/*.ex?' |