{"id":23173860,"url":"https://github.com/sindre0830/workflow-templates","last_synced_at":"2025-08-18T09:30:35.825Z","repository":{"id":37422639,"uuid":"504615082","full_name":"sindre0830/Workflow-Templates","owner":"sindre0830","description":"GitHub Workflows for different programming languages.","archived":false,"fork":false,"pushed_at":"2022-06-27T14:58:33.000Z","size":404,"stargazers_count":13,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-07-30T17:47:15.179Z","etag":null,"topics":["automated-testing","cmake","code-quality","code-review","continuous-integration","cpp","golang","gradle","java","nodejs","python","react","rust","workflows"],"latest_commit_sha":null,"homepage":"","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sindre0830.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null}},"created_at":"2022-06-17T17:11:15.000Z","updated_at":"2023-03-30T15:29:49.000Z","dependencies_parsed_at":"2022-09-07T10:41:37.155Z","dependency_job_id":null,"html_url":"https://github.com/sindre0830/Workflow-Templates","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindre0830%2FWorkflow-Templates","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindre0830%2FWorkflow-Templates/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindre0830%2FWorkflow-Templates/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sindre0830%2FWorkflow-Templates/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sindre0830","download_url":"https://codeload.github.com/sindre0830/Workflow-Templates/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230219995,"owners_count":18192197,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automated-testing","cmake","code-quality","code-review","continuous-integration","cpp","golang","gradle","java","nodejs","python","react","rust","workflows"],"created_at":"2024-12-18T05:18:00.251Z","updated_at":"2024-12-18T05:18:00.933Z","avatar_url":"https://github.com/sindre0830.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Workflow Templates\nTemplates of GitHub Workflows for different programming languages. Place the workflow file you want to use in ```.github/workflows/```. In the ```examples/``` directory, there are coding examples that the workflows run on.\n\nWant to **contribute**? Open up a pull request or an issue! My goal is to have as many languages here as possible so any contribution is welcome.\n\n### List of available templates\n\n| Language | Author(s) |\n| -------- | --------- |\n| [Python](.github/workflows/python.yml) | [sindre0830](https://github.com/sindre0830) |\n| [Golang](.github/workflows/golang.yml) | [sindre0830](https://github.com/sindre0830) |\n| [Node / React](.github/workflows/node.yml) | [sindre0830](https://github.com/sindre0830) |\n| [CMake / C++](.github/workflows/cmake.yml) | [sindre0830](https://github.com/sindre0830) |\n| [Rust](.github/workflows/rust.yml) | [sindre0830](https://github.com/sindre0830) |\n| [Gradle / Java](.github/workflows/java.yml) | [MikAoJK](https://github.com/MikAoJK) |\n\n### Base layout\n\nBase workflow layout for every programming language:\n```yml\nname: Name of workflow\n# when to run the workflow\non:\n  push:\n    ...\n  pull_request:\n  workflow_dispatch:\n# instructions the workflow will perform\njobs:\n  build:\n    # environment to run on\n    runs-on: ubuntu-latest\n    # steps to perform\n    steps:\n    - uses: actions/checkout@v2\n\n    - name: Set up language\n      ...\n\n    - name: Install dependencies\n      working-directory: path/to/folder\n      ...\n\n    - name: Build program\n      working-directory: path/to/folder\n      ...\n\n    - name: Run tests\n      working-directory: path/to/folder\n      ...\n\n    - name: Syntax checker\n      working-directory: path/to/folder\n      ...\n```\n\nUnder the section that decides when to run the workflow you can decide on specific paths. Below you can see an example where the workflow will only run when changes is pushed to the ```path/to/file/main.py``` file or when anything changes in the ```path/to/folder/``` directory. This limits the amount of time the workflow is run and helps with reducing the time it takes to get the results. It is recommended to add the workflow file to this list as it triggers the workflow to run on any changes you apply to it, testing the workflow instantly.\n\nPull requests aren't set to any specific path since it's recommended to run every workflow before merging the branch with main. This reduces the likelihood of mistakes being pushed to the main branch.\n\nThe last trigger is the ```workflow_dispatch```. This allows for a manual trigger of the workflow on the branch of your wish. You should get the option under the action page of the workflow.\n\n```yml\non:\n  push:\n    paths:\n    - 'path/to/file/main.py'\n    - 'path/to/folder/**'\n  pull_request:\n```\n\nUnder the section that is named ```set up language``` you decide the programming language that is relevant for the workflow. Below you have an example with Python. The Python version needs to be changed to whats relevant to your needs.\n\n```yml\n    - name: Set up Python\n      uses: actions/setup-python@v2\n      with:\n        python-version: '3.9.10'\n```\n\nThe rest of the steps are all different depending on the language. The step running the tests might not be relevant for each workflow so might not be present. You can change the path in the working directory to ```.``` if you wish to work in the root directory.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsindre0830%2Fworkflow-templates","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsindre0830%2Fworkflow-templates","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsindre0830%2Fworkflow-templates/lists"}