GitHub Actions Best Practices - abcxyz/readability GitHub Wiki
GitHub Actions Best Practices
🚧 This document is a work in progress 🚧
Objective
We desire a consistent GitHub actions style in our code base. This document proposes a common set of standards for writing GitHub actions and workflows within Bets Platform. This list is by no means thorough. If you find a style worth documenting, add a comment or suggestion for review.
This document is both a style guide and a best practices guide.
Input Naming
- Input names should use snake_case (e.g. project_id).
- Names should be specific and if applicable, should contain a suffix indicating units or sizing as needed (e.g. storage_size_gb).
- For booleans, default to
false
and name appropriately for intended use case
inputs:
# The logging feature is disable by default and the user needs to enable it
enable_logging:
description: "Enable the use of logging"
required: false
default: false
# The cache feature is enabled by default and the user needs to disable it
disable_cache:
description: "Disable the use of caching"
required: false
default: false