-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(01-building-blocks): add README
- Loading branch information
1 parent
67b6905
commit 7aa0139
Showing
2 changed files
with
32 additions
and
0 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# GitHub Actions Workflows, Jobs, and Steps | ||
|
||
GitHub Actions is a powerful automation tool that allows you to build, test, and deploy your code right from your GitHub repository. Understanding the key building blocks — workflows, jobs, and steps — is essential for effective automation. | ||
|
||
## Workflows | ||
|
||
A workflow is a customizable, automated process that you can define in your repository. It's typically used for continuous integration (CI), continuous deployment (CD), and other automation tasks. Here are the important aspects of workflows: | ||
|
||
- **Trigger**: Workflows are triggered by specific events, such as pushes, pull requests, or scheduled events. You define when and how a workflow runs. See the [triggering-workflows](../triggering-workflows/README.md) folder for more information about triggering workflows. | ||
|
||
- **YAML Configuration**: Workflows are defined in a YAML file (e.g., `.github/workflows/main.yml`) within your repository. This configuration file specifies the workflow's name, triggers, jobs, and steps. | ||
|
||
## Jobs | ||
|
||
A job is a unit of work within a workflow. You can have multiple jobs in a workflow, and they can run in parallel or sequentially. Here are the key points about jobs: | ||
|
||
- **Runs-On**: Each job specifies the runner environment, such as Ubuntu, macOS, or Windows. You choose the environment that best suits your workflow. | ||
|
||
- **Parallelism**: You can configure jobs to run concurrently, which can speed up your workflow's execution time. | ||
|
||
## Steps | ||
|
||
A step is an individual task within a job. Steps are the smallest building blocks of a workflow and are where the actual work happens. Here are the important aspects of steps: | ||
|
||
- **Name**: Each step has a name that helps identify its purpose. It appears in the GitHub Actions log to provide clarity during execution. | ||
|
||
- **Run Commands**: Steps execute commands or scripts. These can include shell commands, script files, or even invoking actions from external sources (GitHub Marketplace, your own custom actions, etc.). | ||
|
||
- **Inputs and Outputs**: Steps can have inputs and produce outputs, allowing them to communicate and share data with other steps. |