Update cheatsheets

This commit is contained in:
ivuorinen
2025-05-12 00:21:19 +00:00
parent 3bbcd70636
commit d902176714
130 changed files with 506 additions and 436 deletions

View File

@@ -15,7 +15,7 @@ source: https://github.com/tldr-pages/tldr.git
- Set a `subscription` to be the currently active subscription:
`az account set --subscription {{subscription_id}}`
`az account set {{[-s|--subscription]}} {{subscription_id}}`
- List supported regions for the currently active subscription:
@@ -27,4 +27,4 @@ source: https://github.com/tldr-pages/tldr.git
- Print details of the currently active subscription in a specific format:
`az account show --output {{json|tsv|table|yaml}}`
`az account show {{[-o|--output]}} {{json|tsv|table|yaml}}`

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- Create a managed container registry:
`az acr create --name {{registry_name}} --resource-group {{resource_group}} --sku {{sku}}`
`az acr create {{[-n|--name]}} {{registry_name}} {{[-g|--resource-group]}} {{resource_group}} --sku {{sku}}`
- Login to a registry:
`az acr login --name {{registry_name}}`
`az acr login {{[-n|--name]}} {{registry_name}}`
- Tag a local image for ACR:
@@ -31,12 +31,12 @@ source: https://github.com/tldr-pages/tldr.git
- Delete an image from a registry:
`az acr repository delete --name {{registry_name}} --repository {{image_name}}:{{tag}}`
`az acr repository delete {{[-n|--name]}} {{registry_name}} --repository {{image_name}}:{{tag}}`
- Delete a managed container registry:
`az acr delete --name {{registry_name}} --resource-group {{resource_group}} --yes`
`az acr delete {{[-n|--name]}} {{registry_name}} {{[-g|--resource-group]}} {{resource_group}} {{[-y|--yes]}}`
- List images within a registry:
`az acr repository list --name {{registry_name}} --output table`
`az acr repository list {{[-n|--name]}} {{registry_name}} --output table`

View File

@@ -15,7 +15,7 @@ source: https://github.com/tldr-pages/tldr.git
- Show Azure Advisor configuration for the given subscription or resource group:
`az advisor configuration show --resource_group {{resource_group}}`
`az advisor configuration show {{[-g|--resource-group]}} {{resource_group}}`
- List Azure Advisor recommendations:
@@ -23,8 +23,8 @@ source: https://github.com/tldr-pages/tldr.git
- Enable Azure Advisor recommendations:
`az advisor recommendation enable --resource_group {{resource_group}}`
`az advisor recommendation enable {{[-g|--resource-group]}} {{resource_group}}`
- Disable Azure Advisor recommendations:
`az advisor recommendation disable --resource_group {{resource_group}}`
`az advisor recommendation disable {{[-g|--resource-group]}} {{resource_group}}`

View File

@@ -11,20 +11,20 @@ source: https://github.com/tldr-pages/tldr.git
- List AKS clusters:
`az aks list --resource-group {{resource_group}}`
`az aks list {{[-g|--resource-group]}} {{resource_group}}`
- Create a new AKS cluster:
`az aks create --resource-group {{resource_group}} --name {{name}} --node-count {{count}} --node-vm-size {{size}}`
`az aks create {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{name}} {{[-c|--node-count]}} {{count}} --node-vm-size {{size}}`
- Delete an AKS cluster:
`az aks delete --resource-group {{resource_group}} --name {{name}}`
`az aks delete {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{name}}`
- Get the access credentials for an AKS cluster:
`az aks get-credentials --resource-group {{resource_group}} --name {{name}}`
`az aks get-credentials {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{name}}`
- Get the upgrade versions available for an AKS cluster:
`az aks get-upgrades --resource-group {{resource_group}} --name {{name}}`
`az aks get-upgrades {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{name}}`

View File

@@ -11,20 +11,20 @@ source: https://github.com/tldr-pages/tldr.git
- List API Management services within a resource group:
`az apim list --resource-group {{resource_group}}`
`az apim list {{[-g|--resource-group]}} {{resource_group}}`
- Create an API Management service instance:
`az apim create --name {{name}} --resource-group {{resource_group}} --publisher-email {{email}} --publisher-name {{name}}`
`az apim create {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}} --publisher-email {{email}} --publisher-name {{name}}`
- Delete an API Management service:
`az apim delete --name {{name}} --resource-group {{resource_group}}`
`az apim delete {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- Show details of an API Management service instance:
`az apim show --name {{name}} --resource-group {{resource_group}}`
`az apim show {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- Update an API Management service instance:
`az apim update --name {{name}} --resource-group {{resource_group}}`
`az apim update {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- Create an App Configuration:
`az appconfig create --name {{name}} --resource-group {{group_name}} --location {{location}}`
`az appconfig create {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{group_name}} {{[-l|--location]}} {{location}}`
- Delete a specific App Configuration:
`az appconfig delete --resource-group {{rg_name}} --name {{appconfig_name}}`
`az appconfig delete {{[-g|--resource-group]}} {{rg_name}} {{[-n|--name]}} {{appconfig_name}}`
- List all App Configurations under the current subscription:
@@ -23,12 +23,12 @@ source: https://github.com/tldr-pages/tldr.git
- List all App Configurations under a specific resource group:
`az appconfig list --resource-group {{rg_name}}`
`az appconfig list {{[-g|--resource-group]}} {{rg_name}}`
- Show properties of an App Configuration:
`az appconfig show --name {{appconfig_name}}`
`az appconfig show {{[-n|--name]}} {{appconfig_name}}`
- Update a specific App Configuration:
`az appconfig update --resource-group {{rg_name}} --name {{appconfig_name}}`
`az appconfig update {{[-g|--resource-group]}} {{rg_name}} {{[-n|--name]}} {{appconfig_name}}`

View File

@@ -15,11 +15,11 @@ source: https://github.com/tldr-pages/tldr.git
- Build a Bicep file:
`az bicep build --file {{path/to/file.bicep}}`
`az bicep build {{[-f|--file]}} {{path/to/file.bicep}}`
- Attempt to decompile an ARM template file to a Bicep file:
`az bicep decompile --file {{path/to/template_file.json}}`
`az bicep decompile {{[-f|--file]}} {{path/to/template_file.json}}`
- Upgrade Bicep CLI to the latest version:

View File

@@ -11,20 +11,20 @@ source: https://github.com/tldr-pages/tldr.git
- Set the Personal Access Token (PAT) to login to a particular organization:
`az devops login --organization {{organization_url}}`
`az devops login {{[--org|--organization]}} {{organization_url}}`
- Open a project in the browser:
`az devops project show --project {{project_name}} --open`
`az devops project show {{[-p|--project]}} {{project_name}} --open`
- List members of a specific team working on a particular project:
`az devops team list-member --project {{project_name}} --team {{team_name}}`
`az devops team list-member {{[-p|--project]}} {{project_name}} --team {{team_name}}`
- Check the Azure DevOps CLI current configuration:
`az devops configure --list`
`az devops configure {{[-l|--list]}}`
- Configure the Azure DevOps CLI behavior by setting a default project and a default organization:
`az devops configure --defaults project={{project_name}} organization={{organization_url}}`
`az devops configure {{[-d|--defaults]}} project={{project_name}} organization={{organization_url}}`

View File

@@ -11,20 +11,20 @@ source: https://github.com/tldr-pages/tldr.git
- Create a managed disk:
`az disk create --resource-group {{resource_group}} --name {{disk_name}} --size-gb {{size_in_gb}}`
`az disk create {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{disk_name}} {{[-z|--size-gb]}}{{size_in_gb}}`
- List managed disks in a resource group:
`az disk list --resource-group {{resource_group}}`
`az disk list {{[-g|--resource-group]}} {{resource_group}}`
- Delete a managed disk:
`az disk delete --resource-group {{resource_group}} --name {{disk_name}}`
`az disk delete {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{disk_name}}`
- Grant read or write access to a managed disk (for export):
`az disk grant-access --resource-group {{resource_group}} --name {{disk_name}} --access-level {{Read|Write}} --duration-in-seconds {{seconds}}`
`az disk grant-access {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{disk_name}} {{[--access|--access-level]}} {{Read|Write}} --duration-in-seconds {{seconds}}`
- Update disk size:
`az disk update --resource-group {{resource_group}} --name {{disk_name}} --size-gb {{new_size_in_gb}}`
`az disk update {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{disk_name}} {{[-z|--size-gb]}} {{new_size_in_gb}}`

View File

@@ -11,16 +11,16 @@ source: https://github.com/tldr-pages/tldr.git
- Create a new resource group:
`az group create --name {{name}} --location {{location}}`
`az group create {{[-n|--name]}} {{name}} {{[-l|--location]}} {{location}}`
- Check if a resource group exists:
`az group exists --name {{name}}`
`az group exists {{[-n|--name]}} {{name}}`
- Delete a resource group:
`az group delete --name {{name}}`
`az group delete {{[-n|--name]}} {{name}}`
- Wait until a condition of the resource group is met:
`az group wait --name {{name}} --{{created|deleted|exists|updated}}`
`az group wait {{[-n|--name]}} {{name}} --{{created|deleted|exists|updated}}`

View File

@@ -11,20 +11,20 @@ source: https://github.com/tldr-pages/tldr.git
- List the custom images under a resource group:
`az image list --resource-group {{resource_group}}`
`az image list {{[-g|--resource-group]}} {{resource_group}}`
- Create a custom image from managed disks or snapshots:
`az image create --resource-group {{resource_group}} --name {{name}} --os-type {{windows|linux}} --source {{os_disk_source}}`
`az image create {{[-g|--resource-group]}} {{resource_group}} {{[-n|--name]}} {{name}} --os-type {{windows|linux}} --source {{os_disk_source}}`
- Delete a custom image:
`az image delete --name {{name}} --resource-group {{resource_group}}`
`az image delete {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- Show details of a custom image:
`az image show --name {{name}} --resource-group {{resource_group}}`
`az image show {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- Update custom images:
`az image update --name {{name}} --resource-group {{resource_group}} --set {{property=value}}`
`az image update {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}} --set {{property=value}}`

View File

@@ -11,24 +11,24 @@ source: https://github.com/tldr-pages/tldr.git
- Create a logic app:
`az logicapp create --name {{name}} --resource-group {{resource_group}} --storage-account {{storage_account}}`
`az logicapp create {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}} {{[-s|--storage-account]}} {{storage_account}}`
- Delete a logic app:
`az logicapp delete --name {{name}} --resource-group {{resource_group}}`
`az logicapp delete {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- List logic apps:
`az logicapp list --resource-group {{resource_group}}`
`az logicapp list {{[-g|--resource-group]}} {{resource_group}}`
- Restart a logic app:
`az logicapp restart --name {{name}} --resource-group {{resource_group}}`
`az logicapp restart {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- Start a logic app:
`az logicapp start --name {{name}} --resource-group {{resource_group}}`
`az logicapp start {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- Stop a logic app:
`az logicapp stop --name {{name}} --resource-group {{resource_group}}`
`az logicapp stop {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`

View File

@@ -15,16 +15,16 @@ source: https://github.com/tldr-pages/tldr.git
- Log in with a service principal using a client secret:
`az login --service-principal --username {{http://azure-cli-service-principal}} --password {{secret}} --tenant {{someone.onmicrosoft.com}}`
`az login --service-principal {{[-u|--username]}} {{http://azure-cli-service-principal}} {{[-p|--password]}} {{secret}} --tenant {{someone.onmicrosoft.com}}`
- Log in with a service principal using a client certificate:
`az login --service-principal --username {{http://azure-cli-service-principal}} --password {{path/to/cert.pem}} --tenant {{someone.onmicrosoft.com}}`
`az login --service-principal {{[-u|--username]}} {{http://azure-cli-service-principal}} {{[-p|--password]}} {{path/to/cert.pem}} {{[-t|--tenant]}} {{someone.onmicrosoft.com}}`
- Log in using a VM's system assigned identity:
`az login --identity`
`az login {{[-i|--identity]}}`
- Log in using a VM's user assigned identity:
`az login --identity --username /subscriptions/{{subscription_id}}/resourcegroups/{{my_rg}}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{{my_id}}`
`az login {{[-i|--identity]}} {{[-u|--username]}} /subscriptions/{{subscription_id}}/resourcegroups/{{my_rg}}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{{my_id}}`

View File

@@ -19,8 +19,8 @@ source: https://github.com/tldr-pages/tldr.git
- Create a virtual network:
`az network vnet create --address-prefixes {{10.0.0.0/16}} --name {{vnet}} --resource_group {{group_name}} --submet-name {{subnet}} --subnet-prefixes {{10.0.0.0/24}}`
`az network vnet create --address-prefixes {{10.0.0.0/16}} {{[-n|--name]}} {{vnet}} {{[-g|--resource-group]}} {{group_name}} --submet-name {{subnet}} --subnet-prefixes {{10.0.0.0/24}}`
- Enable accelerated networking for a network interface card:
`az network nic update --accelerated-networking true --name {{nic}} --resource-group {{resource_group}}`
`az network nic update --accelerated-networking true {{[-n|--name]}} {{nic}} {{[-g|--resource-group]}} {{resource_group}}`

View File

@@ -11,28 +11,28 @@ source: https://github.com/tldr-pages/tldr.git
- Create a new Azure Pipeline (YAML based):
`az pipelines create --org {{organization_url}} --project {{project_name}} --name {{pipeline_name}} --description {{description}} --repository {{repository_name}} --branch {{branch_name}}`
`az pipelines create {{[--org|--organization]}} {{organization_url}} {{[-p|--project]}} {{project_name}} --name {{pipeline_name}} --description {{description}} --repository {{repository_name}} --branch {{branch_name}}`
- Delete a specific pipeline:
`az pipelines delete --org {{organization_url}} --project {{project_name}} --id {{pipeline_id}}`
`az pipelines delete {{[--org|--organization]}} {{organization_url}} {{[-p|--project]}} {{project_name}} --id {{pipeline_id}}`
- List pipelines:
`az pipelines list --org {{organization_url}} --project {{project_name}}`
`az pipelines list {{[--org|--organization]}} {{organization_url}} {{[-p|--project]}} {{project_name}}`
- Enqueue a specific pipeline to run:
`az pipelines run --org {{organization_url}} --project {{project_name}} --name {{pipeline_name}}`
`az pipelines run {{[--org|--organization]}} {{organization_url}} {{[-p|--project]}} {{project_name}} --name {{pipeline_name}}`
- Get the details of a specific pipeline:
`az pipelines show --org {{organization_url}} --project {{project_name}} --name {{pipeline_name}}`
`az pipelines show {{[--org|--organization]}} {{organization_url}} {{[-p|--project]}} {{project_name}} --name {{pipeline_name}}`
- Update a specific pipeline:
`az pipelines update --org {{organization_url}} --project {{project_name}} --name {{pipeline_name}} --new-name {{pipeline_new_name}} --new-folder-path {{user1/production_pipelines}}`
`az pipelines update {{[--org|--organization]}} {{organization_url}} {{[-p|--project]}} {{project_name}} --name {{pipeline_name}} --new-name {{pipeline_new_name}} --new-folder-path {{user1/production_pipelines}}`
- List all agents in a pool:
`az pipelines agent list --org {{organization_url}} --pool-id {{agent_pool}}`
`az pipelines agent list {{[--org|--organization]}} {{organization_url}} --pool-id {{agent_pool}}`

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- Register a provider:
`az provider register --namespace {{Microsoft.PolicyInsights}}`
`az provider register {{[-n|--namespace]}} {{Microsoft.PolicyInsights}}`
- Unregister a provider:
`az provider unregister --namespace {{Microsoft.Automation}}`
`az provider unregister {{[-n|--namespace]}} {{Microsoft.Automation}}`
- List all providers for a subscription:
@@ -23,7 +23,7 @@ source: https://github.com/tldr-pages/tldr.git
- Show information about a specific provider:
`az provider show --namespace {{Microsoft.Storage}}`
`az provider show {{[-n|--namespace]}} {{Microsoft.Storage}}`
- List all resource types for a specific provider:

View File

@@ -11,16 +11,16 @@ source: https://github.com/tldr-pages/tldr.git
- Create a new Redis cache instance:
`az redis create --location {{location}} --name {{name}} --resource-group {{resource_group}} --sku {{Basic|Premium|Standard}} --vm-size {{c0|c1|c2|c3|c4|c5|c6|p1|p2|p3|p4|p5}}`
`az redis create --location {{location}} {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}} --sku {{Basic|Premium|Standard}} --vm-size {{c0|c1|c2|c3|c4|c5|c6|p1|p2|p3|p4|p5}}`
- Update a Redis cache:
`az redis update --name {{name}} --resource-group {{resource_group}} --sku {{Basic|Premium|Standard}} --vm-size {{c0|c1|c2|c3|c4|c5|c6|p1|p2|p3|p4|p5}}`
`az redis update {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}} --sku {{Basic|Premium|Standard}} --vm-size {{c0|c1|c2|c3|c4|c5|c6|p1|p2|p3|p4|p5}}`
- Export data stored in a Redis cache:
`az redis export --container {{container}} --file-format {{file-format}} --name {{name}} --prefix {{prefix}} --resource-group {{resource_group}}`
`az redis export --container {{container}} --file-format {{file-format}} {{[-n|--name]}} {{name}} --prefix {{prefix}} {{[-g|--resource-group]}} {{resource_group}}`
- Delete a Redis cache:
`az redis delete --name {{name}} --resource-group {{resource_group}} --yes`
`az redis delete {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}} {{[-y|--yes]}}`

View File

@@ -11,7 +11,7 @@ source: https://github.com/tldr-pages/tldr.git
- List all repos in a specific project:
`az repos list --project {{project_name}}`
`az repos list {{[-p|--project]}} {{project_name}}`
- Add policy on a specific branch of a specific repository to restrict basic merge:
@@ -23,4 +23,4 @@ source: https://github.com/tldr-pages/tldr.git
- List all active Pull Requests on a specific repository within a specific project:
`az repos pr list --project {{project_name}} --repository {{repository_name}} --status active`
`az repos pr list {{[-p|--project]}} {{project_name}} {{[-r|--repository]}} {{repository_name}} --status active`

View File

@@ -11,7 +11,7 @@ source: https://github.com/tldr-pages/tldr.git
- Connect to a serial console:
`az serial-console connect --resource-group {{Resource_Group_Name}} --name {{Virtual_Machine_Name}}`
`az serial-console connect {{[-g|--resource-group]}} {{Resource_Group_Name}} {{[-n|--name]}} {{Virtual_Machine_Name}}`
- Terminate the connection:

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- Create a new SSH key:
`az sshkey create --name {{name}} --resource-group {{resource_group}}`
`az sshkey create --name {{name}} {{[-g|--resource-group]}} {{resource_group}}`
- Upload an existing SSH key:
`az sshkey create --name {{name}} --resource-group {{resource_group}} --public-key "{{@path/to/key.pub}}"`
`az sshkey create --name {{name}} {{[-g|--resource-group]}} {{resource_group}} --public-key "{{@path/to/key.pub}}"`
- List all SSH public keys:
@@ -23,4 +23,4 @@ source: https://github.com/tldr-pages/tldr.git
- Show information about an SSH public key:
`az sshkey show --name {{name}} --resource-group {{resource_group}}`
`az sshkey show --name {{name}} {{[-g|--resource-group]}} {{resource_group}}`

View File

@@ -11,16 +11,16 @@ source: https://github.com/tldr-pages/tldr.git
- Create an storage account:
`az storage account create --name {{storage_account_name}} --resource-group {{azure_resource_group}} --location {{azure_location}} --sku {{storage_account_sku}}`
`az storage account create {{[-n|--name]}} {{storage_account_name}} {{[-g|--resource-group]}} {{azure_resource_group}} --location {{azure_location}} --sku {{storage_account_sku}}`
- Generate a shared access signature for a specific storage account:
`az storage account generate-sas --account-name {{storage_account_name}} --name {{account_name}} --permissions {{sas_permissions}} --expiry {{expiry_date}} --services {{storage_services}} --resource-types {{resource_types}}`
`az storage account generate-sas --account-name {{storage_account_name}} {{[-n|--name]}} {{account_name}} --permissions {{sas_permissions}} --expiry {{expiry_date}} --services {{storage_services}} --resource-types {{resource_types}}`
- List storage accounts:
`az storage account list --resource-group {{azure_resource_group}}`
`az storage account list {{[-g|--resource-group]}} {{azure_resource_group}}`
- Delete a specific storage account:
`az storage account delete --name {{storage_account_name}} --resource-group {{azure_resource_group}}`
`az storage account delete {{[-n|--name]}} {{storage_account_name}} {{[-g|--resource-group]}} {{azure_resource_group}}`

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- Create a container in a storage account:
`az storage container create --account-name {{storage_account_name}} --name {{container_name}} --public-access {{access_level}} --fail-on-exist`
`az storage container create --account-name {{storage_account_name}} {{[-n|--name]}} {{container_name}} --public-access {{access_level}} --fail-on-exist`
- Generate a shared access signature for the container:
`az storage container generate-sas --account-name {{storage_account_name}} --name {{container_name}} --permissions {{sas_permissions}} --expiry {{expiry_date}} --https-only`
`az storage container generate-sas --account-name {{storage_account_name}} {{[-n|--name]}} {{container_name}} --permissions {{sas_permissions}} --expiry {{expiry_date}} --https-only`
- List containers in a storage account:
@@ -23,4 +23,4 @@ source: https://github.com/tldr-pages/tldr.git
- Mark the specified container for deletion:
`az storage container delete --account-name {{storage_account_name}} --name {{container_name}} --fail-not-exist`
`az storage container delete --account-name {{storage_account_name}} {{[-n|--name]}} {{container_name}} --fail-not-exist`

View File

@@ -11,20 +11,20 @@ source: https://github.com/tldr-pages/tldr.git
- Insert an entity into a table:
`az storage entity insert --entity {{space_separated_key_value_pairs}} --table-name {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
`az storage entity insert {{[-e|--entity]}} {{space_separated_key_value_pairs}} {{[-t|--table-name]}} {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
- Delete an existing entity from a table:
`az storage entity delete --partition-key {{partition_key}} --row-key {{row_key}} --table-name {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
`az storage entity delete --partition-key {{partition_key}} --row-key {{row_key}} {{[-t|--table-name]}} {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
- Update an existing entity by merging its properties:
`az storage entity merge --entity {{space_separated_key_value_pairs}} --table-name {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
`az storage entity merge {{[-e|--entity]}} {{space_separated_key_value_pairs}} {{[-t|--table-name]}} {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
- List entities which satisfy a query:
`az storage entity query --filter {{query_filter}} --table-name {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
`az storage entity query --filter {{query_filter}} {{[-t|--table-name]}} {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
- Get an entity from the specified table:
`az storage entity show --partition-key {{partition_key}} --row-key {{row_key}} --table-name {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`
`az storage entity show --partition-key {{partition_key}} --row-key {{row_key}} {{[-t|--table-name]}} {{table_name}} --account-name {{storage_account_name}} --account-key {{storage_account_key}}`

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- Create a queue:
`az storage queue create --account-name {{storage_account_name}} --name {{queue_name}} --metadata {{queue_metadata}}`
`az storage queue create --account-name {{storage_account_name}} {{[-n|--name]}} {{queue_name}} --metadata {{queue_metadata}}`
- Generate a shared access signature for the queue:
`az storage queue generate-sas --account-name {{storage_account_name}} --name {{queue_name}} --permissions {{queue_permissions}} --expiry {{expiry_date}} --https-only`
`az storage queue generate-sas --account-name {{storage_account_name}} {{[-n|--name]}} {{queue_name}} --permissions {{queue_permissions}} --expiry {{expiry_date}} --https-only`
- List queues in a storage account:
@@ -23,4 +23,4 @@ source: https://github.com/tldr-pages/tldr.git
- Delete the specified queue and any messages it contains:
`az storage queue delete --account-name {{storage_account_name}} --name {{queue_name}} --fail-not-exist`
`az storage queue delete --account-name {{storage_account_name}} {{[-n|--name]}} {{queue_name}} --fail-not-exist`

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- Create a new table in the storage account:
`az storage table create --account-name {{storage_account_name}} --name {{table_name}} --fail-on-exist`
`az storage table create --account-name {{storage_account_name}} {{[-n|--name]}} {{table_name}} --fail-on-exist`
- Generate a shared access signature for the table:
`az storage table generate-sas --account-name {{storage_account_name}} --name {{table_name}} --permissions {{sas_permissions}} --expiry {{expiry_date}} --https-only`
`az storage table generate-sas --account-name {{storage_account_name}} {{[-n|--name]}} {{table_name}} --permissions {{sas_permissions}} --expiry {{expiry_date}} --https-only`
- List tables in a storage account:
@@ -23,4 +23,4 @@ source: https://github.com/tldr-pages/tldr.git
- Delete the specified table and any data it contains:
`az storage table delete --account-name {{storage_account_name}} --name {{table_name}} --fail-not-exist`
`az storage table delete --account-name {{storage_account_name}} {{[-n|--name]}} {{table_name}} --fail-not-exist`

View File

@@ -11,15 +11,15 @@ source: https://github.com/tldr-pages/tldr.git
- Create a tag value:
`az tag add-value --name {{tag_name}} --value {{tag_value}}`
`az tag add-value {{[-n|--name]}} {{tag_name}} --value {{tag_value}}`
- Create a tag in the subscription:
`az tag create --name {{tag_name}}`
`az tag create {{[-n|--name]}} {{tag_name}}`
- Delete a tag from the subscription:
`az tag delete --name {{tag_name}}`
`az tag delete {{[-n|--name]}} {{tag_name}}`
- List all tags on a subscription:
@@ -27,4 +27,4 @@ source: https://github.com/tldr-pages/tldr.git
- Delete a tag value for a specific tag name:
`az tag remove-value --name {{tag_name}} --value {{tag_value}}`
`az tag remove-value {{[-n|--name]}} {{tag_name}} --value {{tag_value}}`

View File

@@ -19,4 +19,4 @@ source: https://github.com/tldr-pages/tldr.git
- Upgrade Azure CLI and Extensions without prompting for confirmation:
`az version --all --yes`
`az version --all {{[-y|--yes]}}`

View File

@@ -15,4 +15,4 @@ source: https://github.com/tldr-pages/tldr.git
- Show the current version of Azure CLI modules and extensions in a given format:
`az version --output {{json|table|tsv}}`
`az version {{[-o|--output]}} {{json|table|tsv}}`

View File

@@ -15,23 +15,23 @@ source: https://github.com/tldr-pages/tldr.git
- Create a virtual machine using the default Ubuntu image and generate SSH keys:
`az vm create --resource-group {{rg}} --name {{vm_name}} --image {{UbuntuLTS}} --admin-user {{azureuser}} --generate-ssh-keys`
`az vm create {{[-g|--resource-group]}} {{rg}} {{[-n|--name]}} {{vm_name}} --image {{UbuntuLTS}} --admin-user {{azureuser}} --generate-ssh-keys`
- Stop a Virtual Machine:
`az vm stop --resource-group {{rg}} --name {{vm_name}}`
`az vm stop {{[-g|--resource-group]}} {{rg}} {{[-n|--name]}} {{vm_name}}`
- Deallocate a Virtual Machine:
`az vm deallocate --resource-group {{rg}} --name {{vm_name}}`
`az vm deallocate {{[-g|--resource-group]}} {{rg}} {{[-n|--name]}} {{vm_name}}`
- Start a Virtual Machine:
`az vm start --resource-group {{rg}} --name {{vm_name}}`
`az vm start {{[-g|--resource-group]}} {{rg}} {{[-n|--name]}} {{vm_name}}`
- Restart a Virtual Machine:
`az vm restart --resource-group {{rg}} --name {{vm_name}}`
`az vm restart {{[-g|--resource-group]}} {{rg}} {{[-n|--name]}} {{vm_name}}`
- List VM images available in the Azure Marketplace:

View File

@@ -11,11 +11,11 @@ source: https://github.com/tldr-pages/tldr.git
- List available runtimes for a web application:
`az webapp list-runtimes --os-type {{windows|linux}}`
`az webapp list-runtimes {{[-os|--os-type]}} {{windows|linux}}`
- Create a web application:
`az webapp up --name {{name}} --location {{location}} --runtime {{runtime}}`
`az webapp up {{[-n|--name]}} {{name}} {{[-l|--location]}} {{location}} {{[-r|--runtime]}} {{runtime}}`
- List all web applications:
@@ -23,4 +23,4 @@ source: https://github.com/tldr-pages/tldr.git
- Delete a specific web application:
`az webapp delete --name {{name}} --resource-group {{resource_group}}`
`az webapp delete {{[-n|--name]}} {{name}} {{[-g|--resource-group]}} {{resource_group}}`

33
tldr/blahaj Normal file
View File

@@ -0,0 +1,33 @@
---
syntax: markdown
tags: [tldr, common]
source: https://github.com/tldr-pages/tldr.git
---
# blahaj
> A lolcat-like output colorizer that also prints flags and colorful sharks.
> More information: <https://codeberg.org/GeopJr/BLAHAJ>.
- Get a list of possible flags/colors:
`blahaj --flags`
- Print a shark (blahaj) with default trans colors:
`blahaj {{[-s|--shark]}}`
- Print a random flag with a 2x size multiplier:
`blahaj {{[-f|--flag]}} {{[-r|--random]}} {{[-m|--multiplier]}} 2`
- Print the result of a text-producing command with lesbian colors:
`{{cowsay "Hello, world"}} | blahaj {{[-c|--colors]}} lesbian`
- Print text and color by individual character:
`echo "{{Hello, world}}" | blahaj {{[-i|--individual]}}`
- Print contents of a text document, coloring the background instead of text, by word:
`blahaj {{[-w|--words]}} {{[-b|--background]}} {{path/to/file}}`

View File

@@ -14,20 +14,20 @@ source: https://github.com/tldr-pages/tldr.git
- Search for extended regular expressions (supporting `?`, `+`, `{}`, `()` and `|`) in a compressed file (case-insensitive):
`bzegrep --ignore-case "{{search_pattern}}" {{path/to/file}}`
`bzegrep {{[-i|--ignore-case]}} "{{search_pattern}}" {{path/to/file}}`
- Search for lines that do not match a pattern:
`bzegrep --invert-match "{{search_pattern}}" {{path/to/file}}`
`bzegrep {{[-v|--invert-match]}} "{{search_pattern}}" {{path/to/file}}`
- Print file name and line number for each match:
`bzegrep --with-filename --line-number "{{search_pattern}}" {{path/to/file}}`
`bzegrep {{[-H|--with-filename]}} {{[-n|--line-number]}} "{{search_pattern}}" {{path/to/file}}`
- Search for lines matching a pattern, printing only the matched text:
`bzegrep --only-matching "{{search_pattern}}" {{path/to/file}}`
`bzegrep {{[-o|--only-matching]}} "{{search_pattern}}" {{path/to/file}}`
- Recursively search files in a bzip2 compressed tar archive for a pattern:
`bzegrep --recursive "{{search_pattern}}" {{path/to/file}}`
`bzegrep {{[-r|--recursive]}} "{{search_pattern}}" {{path/to/file}}`

View File

@@ -14,20 +14,20 @@ source: https://github.com/tldr-pages/tldr.git
- Search for lines matching the list of search strings separated by new lines in a compressed file (case-insensitive):
`bzfgrep --ignore-case "{{search_string}}" {{path/to/file}}`
`bzfgrep {{[-i|--ignore-case]}} "{{search_string}}" {{path/to/file}}`
- Search for lines that do not match the list of search strings separated by new lines in a compressed file:
`bzfgrep --invert-match "{{search_string}}" {{path/to/file}}`
`bzfgrep {{[-v|--invert-match]}} "{{search_string}}" {{path/to/file}}`
- Print file name and line number for each match:
`bzfgrep --with-filename --line-number "{{search_string}}" {{path/to/file}}`
`bzfgrep {{[-H|--with-filename]}} {{[-n|--line-number]}} "{{search_string}}" {{path/to/file}}`
- Search for lines matching a pattern, printing only the matched text:
`bzfgrep --only-matching "{{search_string}}" {{path/to/file}}`
`bzfgrep {{[-o|--only-matching]}} "{{search_string}}" {{path/to/file}}`
- Recursively search files in a bzip2 compressed tar archive for the given list of strings:
`bzfgrep --recursive "{{search_string}}" {{path/to/file}}`
`bzfgrep {{[-r|--recursive]}} "{{search_string}}" {{path/to/file}}`

View File

@@ -14,24 +14,24 @@ source: https://github.com/tldr-pages/tldr.git
- Use extended regular expressions (supports `?`, `+`, `{}`, `()` and `|`), in case-insensitive mode:
`bzgrep --extended-regexp --ignore-case "{{search_pattern}}" {{path/to/file}}`
`bzgrep {{[-E|--extended-regexp]}} {{[-i|--ignore-case]}} "{{search_pattern}}" {{path/to/file}}`
- Print 3 lines of context around, before, or after each match:
- Print 3 lines of [C]ontext around, [B]efore, or [A]fter each match:
`bzgrep --{{context|before-context|after-context}}={{3}} "{{search_pattern}}" {{path/to/file}}`
`bzgrep --{{context|before-context|after-context}} {{3}} "{{search_pattern}}" {{path/to/file}}`
- Print file name and line number for each match:
`bzgrep --with-filename --line-number "{{search_pattern}}" {{path/to/file}}`
`bzgrep {{[-H|--with-filename]}} {{[-n|--line-number]}} "{{search_pattern}}" {{path/to/file}}`
- Search for lines matching a pattern, printing only the matched text:
`bzgrep --only-matching "{{search_pattern}}" {{path/to/file}}`
`bzgrep {{[-o|--only-matching]}} "{{search_pattern}}" {{path/to/file}}`
- Recursively search files in a bzip2 compressed tar archive for a pattern:
`bzgrep --recursive "{{search_pattern}}" {{path/to/tar/file}}`
`bzgrep {{[-r|--recursive]}} "{{search_pattern}}" {{path/to/tar/file}}`
- Search `stdin` for lines that do not match a pattern:
`cat {{/path/to/bz/compressed/file}} | bzgrep --invert-match "{{search_pattern}}"`
`cat {{/path/to/bz/compressed/file}} | bzgrep {{[-v|--invert-match]}} "{{search_pattern}}"`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# code
> Cross platform and extensible code editor.
> More information: <https://github.com/microsoft/vscode>.
> More information: <https://code.visualstudio.com/docs/configure/command-line>.
- Start Visual Studio Code:
@@ -18,19 +18,19 @@ source: https://github.com/tldr-pages/tldr.git
- Compare two specific files:
`code --diff {{path/to/file1}} {{path/to/file2}}`
`code {{[-d|--diff]}} {{path/to/file1}} {{path/to/file2}}`
- Open specific files/directories in a new window:
`code --new-window {{path/to/file_or_directory1 path/to/file_or_directory2 ...}}`
`code {{[-n|--new-window]}} {{path/to/file_or_directory1 path/to/file_or_directory2 ...}}`
- Install/uninstall a specific extension:
`code --{{install|uninstall}}-extension {{publisher.extension}}`
- Print installed extensions:
- Display diagnostic and process information about the running code window:
`code --list-extensions`
`code {{[-s|--status]}}`
- Print installed extensions with their versions:

View File

@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- Forcefully overwrite files:
`cradle install --force`
`cradle install {{[-f|--force]}}`
- Skip running SQL migrations:

View File

@@ -10,11 +10,11 @@ source: https://github.com/tldr-pages/tldr.git
- Display account info:
`doctl account get`
`doctl account {{[g|get]}}`
- Show the hourly API limit, progress towards it, and when the rate limit resets:
`doctl account ratelimit`
`doctl account {{[rl|ratelimit]}}`
- Display help:

View File

@@ -10,32 +10,32 @@ source: https://github.com/tldr-pages/tldr.git
- Create an app:
`doctl apps create`
`doctl {{[a|apps]}} {{[c|create]}}`
- Create a deployment for a specific app:
`doctl apps create-deployment {{app_id}}`
`doctl {{[a|apps]}} {{[cd|create-deployment]}} {{app_id}}`
- Delete an app interactively:
`doctl apps delete {{app_id}}`
`doctl {{[a|apps]}} {{[d|delete]}} {{app_id}}`
- Get an app:
`doctl apps get`
`doctl {{[a|apps]}} {{[g|get]}}`
- List all apps:
`doctl apps list`
`doctl {{[a|apps]}} {{[ls|list]}}`
- List all deployments from a specific app:
`doctl apps list-deployments {{app_id}}`
`doctl {{[a|apps]}} {{[lsd|list-deployments]}} {{app_id}}`
- Get logs from a specific app:
`doctl apps logs {{app_id}}`
`doctl {{[a|apps]}} {{[l|logs]}} {{app_id}}`
- Update a specific app with a given app spec:
`doctl apps update {{app_id}} --spec {{path/to/spec.yml}}`
`doctl {{[a|apps]}} {{[u|update]}} {{app_id}} --spec {{path/to/spec.yml}}`

View File

@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- List authentication contexts (API tokens):
`doctl auth list`
`doctl auth {{[ls|list]}}`
- Switch contexts (API tokens):

View File

@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
- Get balance of the account associated with the current context:
`doctl balance get`
`doctl balance {{[g|get]}}`
- Get the balance of an account associated with an access token:
`doctl balance get {{[-t|--access-token]}} {{access_token}}`
`doctl balance {{[g|get]}} {{[-t|--access-token]}} {{access_token}}`
- Get the balance of an account associated with a specified context:
`doctl balance get --context`
`doctl balance {{[g|get]}} --context`

View File

@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
- Create a droplet:
`doctl compute droplet create --region {{region}} --image {{os_image}} --size {{vps_type}} {{droplet_name}}`
`doctl compute {{[d|droplet]}} {{[c|create]}} --region {{region}} --image {{os_image}} --size {{vps_type}} {{droplet_name}}`
- Delete a droplet:
`doctl compute droplet delete {{droplet_id|droplet_name}}`
`doctl compute {{[d|droplet]}} {{[d|delete]}} {{droplet_id|droplet_name}}`
- List droplets:
`doctl compute droplet list`
`doctl compute {{[d|droplet]}} {{[ls|list]}}`

View File

@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases` command with an access token:
`doctl databases {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Get details for a database cluster:
`doctl databases get`
`doctl {{[d|databases]}} {{[g|get]}}`
- List your database clusters:
`doctl databases list`
`doctl {{[d|databases]}} {{[ls|list]}}`
- Create a database cluster:
`doctl databases create {{database_name}}`
`doctl {{[d|databases]}} {{[c|create]}} {{database_name}}`
- Delete a cluster:
`doctl databases delete {{database_id}}`
`doctl {{[d|databases]}} {{[rm|delete]}} {{database_id}}`

View File

@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases db` command with an access token:
`doctl databases db {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} db {{command}} {{[-t|--access-token]}} {{access_token}}`
- Retrieve the name of the given database hosted in the given database cluster:
`doctl databases db get {{database_id}} {{database_name}}`
`doctl {{[d|databases]}} db {{[g|get]}} {{database_id}} {{database_name}}`
- List existing databases hosted within a given database cluster:
`doctl databases db list {{database_id}}`
`doctl {{[d|databases]}} db {{[ls|list]}} {{database_id}}`
- Create a database with the given name in the given database cluster:
`doctl databases db create {{database_id}} {{database_name}}`
`doctl {{[d|databases]}} db {{[c|create]}} {{database_id}} {{database_name}}`
- Delete the database with the given name in the given database cluster:
`doctl databases db delete {{database_id}} {{database_name}}`
`doctl {{[d|databases]}} db {{[rm|delete]}} {{database_id}} {{database_name}}`

View File

@@ -10,16 +10,16 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases firewalls` command with an access token:
`doctl databases firewalls {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{[fw|firewalls]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Retrieve a list of firewall rules for a given database:
`doctl databases firewalls list`
`doctl {{[d|databases]}} {{[fw|firewalls]}} {{[ls|list]}}`
- Add a database firewall rule to a given database:
`doctl databases firewalls append {{database_id}} --rule {{droplet|k8s|ip_addr|tag|app}}:{{value}}`
`doctl {{[d|databases]}} {{[fw|firewalls]}} {{[a|append]}} {{database_id}} --rule {{droplet|k8s|ip_addr|tag|app}}:{{value}}`
- Remove a firewall rule for a given database:
`doctl databases firewalls remove {{database_id}} {{rule_uuid}}`
`doctl {{[d|databases]}} {{[fw|firewalls]}} {{[rm|remove]}} {{database_id}} {{rule_uuid}}`

View File

@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases maintenance-window` command with an access token:
`doctl databases maintenance-window {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{[mw|maintenance-window]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Retrieve details about a database cluster's maintenance windows:
`doctl databases maintenance-window get {{database_id}}`
`doctl {{[d|databases]}} {{[mw|maintenance-window]}} {{[g|get]}} {{database_id}}`
- Update the maintenance window for a database cluster:
`doctl databases maintenance-window update {{database_id}} --day {{day_of_the_week}} --hour {{hour_in_24_hours_format}}`
`doctl {{[d|databases]}} {{[mw|maintenance-window]}} {{[u|update]}} {{database_id}} --day {{day_of_the_week}} --hour {{hour_in_24_hours_format}}`

View File

@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases options` command with an access token:
`doctl databases options {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{[o|options]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Retrieve a list of the available database engines:
`doctl databases options engines`
`doctl {{[d|databases]}} {{[o|options]}} {{[eng|engines]}}`
- Retrieve a list of the available regions for a given database engine:
`doctl databases options regions --engine {{pg|mysql|redis|mongodb}}`
`doctl {{[d|databases]}} {{[o|options]}} {{[r|regions]}} --engine {{pg|mysql|redis|mongodb}}`
- Retrieve a list of the available slugs for a given database engine:
`doctl databases options slugs --engine {{pg|mysql|redis|mongodb}}`
`doctl {{[d|databases]}} {{[o|options]}} {{[s|slugs]}} --engine {{pg|mysql|redis|mongodb}}`
- Retrieve a list of the available versions for a given database engine:
`doctl databases options versions --engine {{pg|mysql|redis|mongodb}}`
`doctl {{[d|databases]}} {{[o|options]}} {{[v|versions]}} --engine {{pg|mysql|redis|mongodb}}`

View File

@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases pool` command with an access token:
`doctl databases pool {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{[p|pool]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Retrieve information about a database connection pool:
`doctl databases pool get {{database_id}} {{pool_name}}`
`doctl {{[d|databases]}} {{[p|pool]}} {{[g|get]}} {{database_id}} {{pool_name}}`
- List connection pools for a database cluster:
`doctl databases pool list {{database_id}}`
`doctl {{[d|databases]}} {{[p|pool]}} {{[ls|list]}} {{database_id}}`
- Create a connection pool for a database:
`doctl databases pool create {{database_id}} {{pool_name}} --db {{new_pool_name}} --size {{pool_size}}`
`doctl {{[d|databases]}} {{[p|pool]}} {{[c|create]}} {{database_id}} {{pool_name}} --db {{new_pool_name}} --size {{pool_size}}`
- Delete a connection pool for a database:
`doctl databases pool create {{database_id}} {{pool_name}}`
`doctl {{[d|databases]}} {{[p|pool]}} {{[c|create]}} {{database_id}} {{pool_name}}`

View File

@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases replica` command with an access token:
`doctl databases pool {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{[p|pool]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Retrieve information about a read-only database replica:
`doctl databases replica get {{database_id}} {{replica_name}}`
`doctl {{[d|databases]}} {{[r|replica]}} {{[g|get]}} {{database_id}} {{replica_name}}`
- Retrieve list of read-only database replicas:
`doctl databases replica list {{database_id}}`
`doctl {{[d|databases]}} {{[r|replica]}} {{[ls|list]}} {{database_id}}`
- Create a read-only database replica:
`doctl databases replica create {{database_id}} {{replica_name}}`
`doctl {{[d|databases]}} {{[r|replica]}} {{[c|create]}} {{database_id}} {{replica_name}}`
- Delete a read-only database replica:
`doctl databases replica delete {{database_id}} {{replica_name}}`
`doctl {{[d|databases]}} {{[r|replica]}} {{[rm|delete]}} {{database_id}} {{replica_name}}`

View File

@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases sql-mode` command with an access token:
`doctl databases sql-mode {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{[sm|sql-mode]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Get a MySQL database cluster's SQL modes:
`doctl databases sql-mode get {{database_id}}`
`doctl {{[d|databases]}} {{[sm|sql-mode]}} {{[g|get]}} {{database_id}}`
- Overwrite a MySQL database cluster's SQL modes to the specified modes:
`doctl databases sql-mode set {{database_id}} {{sql_mode_1 sql_mode_2 ...}}`
`doctl {{[d|databases]}} {{[sm|sql-mode]}} {{[s|set]}} {{database_id}} {{sql_mode_1 sql_mode_2 ...}}`

View File

@@ -10,28 +10,28 @@ source: https://github.com/tldr-pages/tldr.git
- Run a `doctl databases user` command with an access token:
`doctl databases user {{command}} {{[-t|--access-token]}} {{access_token}}`
`doctl {{[d|databases]}} {{[u|user]}} {{command}} {{[-t|--access-token]}} {{access_token}}`
- Retrieve details about a database user:
`doctl databases user get {{database_id}} {{user_name}}`
`doctl {{[d|databases]}} {{[u|user]}} {{[g|get]}} {{database_id}} {{user_name}}`
- Retrieve a list of database users for a given database:
`doctl databases user list {{database_id}}`
`doctl {{[d|databases]}} {{[u|user]}} {{[ls|list]}} {{database_id}}`
- Reset the auth password for a given user:
`doctl databases user reset {{database id}} {{user_name}}`
`doctl {{[d|databases]}} {{[u|user]}} {{[rs|reset]}} {{database id}} {{user_name}}`
- Reset the MySQL auth plugn for a given user:
`doctl databases user reset {{database_id}} {{user_name}} {{caching_sha2_password|mysql_native_password}}`
`doctl {{[d|databases]}} {{[u|user]}} {{[rs|reset]}} {{database_id}} {{user_name}} {{caching_sha2_password|mysql_native_password}}`
- Create a user in the given database with a given username:
`doctl databases user create {{database_id}} {{user_name}}`
`doctl {{[d|databases]}} {{[u|user]}} {{[c|create]}} {{database_id}} {{user_name}}`
- Delete a user from the given database with the given username:
`doctl databases user delete {{database_id}} {{user_name}}`
`doctl {{[d|databases]}} {{[u|user]}} {{[rm|delete]}} {{database_id}} {{user_name}}`

View File

@@ -10,24 +10,24 @@ source: https://github.com/tldr-pages/tldr.git
- Create a Kubernetes cluster:
`doctl kubernetes cluster create --count {{3}} --region {{nyc1}} --size {{s-1vcpu-2gb}} --version {{latest}} {{cluster_name}}`
`doctl {{[k|kubernetes]}} {{[c|cluster]}} {{[c|create]}} --count {{3}} --region {{nyc1}} --size {{s-1vcpu-2gb}} --version {{latest}} {{cluster_name}}`
- List all Kubernetes clusters:
`doctl kubernetes cluster list`
`doctl {{[k|kubernetes]}} {{[c|cluster]}} {{[ls|list]}}`
- Fetch and save the kubeconfig:
`doctl kubernetes cluster kubeconfig save {{cluster_name}}`
`doctl {{[k|kubernetes]}} {{[c|cluster]}} {{[cfg|kubeconfig]}} {{[s|save]}} {{cluster_name}}`
- Check for available upgrades:
`doctl kubernetes cluster get-upgrades {{cluster_name}}`
`doctl {{[k|kubernetes]}} {{[c|cluster]}} {{[gu|get-upgrades]}} {{cluster_name}}`
- Upgrade a cluster to a new Kubernetes version:
`doctl kubernetes cluster upgrade {{cluster_name}}`
`doctl {{[k|kubernetes]}} {{[c|cluster]}} upgrade {{cluster_name}}`
- Delete a cluster:
`doctl kubernetes cluster delete {{cluster_name}}`
`doctl {{[k|kubernetes]}} {{[c|cluster]}} {{[d|delete]}} {{cluster_name}}`

View File

@@ -10,12 +10,12 @@ source: https://github.com/tldr-pages/tldr.git
- List regions that support Kubernetes clusters:
`doctl kubernetes options regions`
`doctl {{[k|kubernetes]}} {{[o|options]}} {{[r|regions]}}`
- List machine sizes that can be used in a Kubernetes cluster:
`doctl kubernetes options sizes`
`doctl {{[k|kubernetes]}} {{[o|options]}} {{[s|sizes]}}`
- List Kubernetes versions that can be used with DigitalOcean clusters:
`doctl kubernetes options versions`
`doctl {{[k|kubernetes]}} {{[o|options]}} {{[v|versions]}}`

View File

@@ -10,16 +10,16 @@ source: https://github.com/tldr-pages/tldr.git
- Connect local serverless support to a functions namespace:
`doctl serverless connect`
`doctl {{[sls|serverless]}} connect`
- Deploy a functions project to your functions namespace:
`doctl serverless deploy`
`doctl {{[sls|serverless]}} deploy`
- Obtain metadata of a functions project:
`doctl serverless get-metadata`
`doctl {{[sls|serverless]}} get-metadata`
- Provide information about serverless support:
`doctl serverless status`
`doctl {{[sls|serverless]}} status`

View File

@@ -11,28 +11,28 @@ source: https://github.com/tldr-pages/tldr.git
- Enumerate directories using [c]olored output and a [w]ordlist specifying a target [u]RL:
`ffuf -c -w {{path/to/wordlist.txt}} -u {{http://target/FUZZ}}`
`ffuf -c -w {{path/to/wordlist.txt}} -u {{http://example.com/FUZZ}}`
- Enumerate webservers of subdomains by changing the position of the keyword:
`ffuf -w {{path/to/subdomains.txt}} -u {{http://FUZZ.target.com}}`
`ffuf -w {{path/to/subdomains.txt}} -u {{http://FUZZ.example.com}}`
- Fuzz with specified [t]hreads (default: 40) and pro[x]ying the traffic and save [o]utput to a file:
`ffuf -o -w {{path/to/wordlist.txt}} -u {{http://target/FUZZ}} -t {{500}} -x {{http://127.0.0.1:8080}}`
`ffuf -o -w {{path/to/wordlist.txt}} -u {{http://example.com/FUZZ}} -t {{500}} -x {{http://127.0.0.1:8080}}`
- Fuzz a specific [H]eader ("Name: Value") and [m]atch HTTP status [c]odes:
`ffuf -w {{path/to/wordlist.txt}} -u {{http://target.com}} -H "{{Host: FUZZ}}" -mc {{200}}`
`ffuf -w {{path/to/wordlist.txt}} -u {{http://example.com}} -H "{{Host: FUZZ}}" -mc {{200}}`
- Fuzz with specified HTTP method and [d]ata, while [f]iltering out comma separated status [c]odes:
`ffuf -w {{path/to/postdata.txt}} -X {{POST}} -d "{{username=admin\&password=FUZZ}}" -u {{http://target/login.php}} -fc {{401,403}}`
`ffuf -w {{path/to/postdata.txt}} -X {{POST}} -d "{{username=admin\&password=FUZZ}}" -u {{http://example.com/login.php}} -fc {{401,403}}`
- Fuzz multiple positions with multiple wordlists using different modes:
`ffuf -w {{path/to/keys:KEY}} -w {{path/to/values:VALUE}} -mode {{pitchfork|clusterbomb}} -u {{http://target.com/id?KEY=VALUE}}`
`ffuf -w {{path/to/keys:KEY}} -w {{path/to/values:VALUE}} -mode {{pitchfork|clusterbomb}} -u {{http://example.com/id?KEY=VALUE}}`
- Proxy requests through a HTTP MITM pro[x]y (such as Burp Suite or `mitmproxy`):
`ffuf -w {{path/to/wordlist}} -x {{http://127.0.0.1:8080}} -u {{http://target.com/FUZZ}}`
`ffuf -w {{path/to/wordlist}} -x {{http://127.0.0.1:8080}} -u {{http://example.com/FUZZ}}`

View File

@@ -12,13 +12,13 @@ source: https://github.com/tldr-pages/tldr.git
`fossil commit`
- Create a new version containing all the changes in the current checkout, using the specified comment:
- Create a new version containing all the changes in the current checkout, using the specified [m]essage:
`fossil commit --comment "{{comment}}"`
`fossil commit {{[-m|--comment]}} "{{comment}}"`
- Create a new version containing all the changes in the current checkout with a comment read from a specific file:
`fossil commit --message-file {{path/to/commit_message_file}}`
`fossil commit {{[-M|--message-file]}} {{path/to/commit_message_file}}`
- Create a new version containing changes from the specified files; user will be prompted for a comment:

View File

@@ -7,7 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> Work seamlessly with GitLab.
> Some subcommands such as `config` have their own usage documentation.
> More information: <https://github.com/profclems/glab>.
> More information: <https://gitlab.com/gitlab-org/cli/-/tree/main/docs/source>.
- Clone a GitLab repository locally:
@@ -23,7 +23,7 @@ source: https://github.com/tldr-pages/tldr.git
- View an issue in the default browser:
`glab issue view --web {{issue_number}}`
`glab issue view {{[-w|--web]}} {{issue_number}}`
- Create a merge request:
@@ -31,7 +31,7 @@ source: https://github.com/tldr-pages/tldr.git
- View a pull request in the default web browser:
`glab mr view --web {{pr_number}}`
`glab mr view {{[-w|--web]}} {{pr_number}}`
- Check out a specific pull request locally:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab alias
> Manage GitLab CLI command aliases.
> More information: <https://glab.readthedocs.io/en/latest/alias>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/alias/index.md>.
- Display the subcommand help:
@@ -22,7 +22,7 @@ source: https://github.com/tldr-pages/tldr.git
- Set a shell command as a `glab` subcommand:
`glab alias set --shell {{alias_name}} {{command}}`
`glab alias set {{[-s|--shell]}} {{alias_name}} {{command}}`
- Delete a command shortcut:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab auth
> Authenticate with a GitLab host.
> More information: <https://glab.readthedocs.io/en/latest/auth>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/auth/index.md>.
- Log in with interactive prompt:
@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- Log in with a token:
`glab auth login --token {{token}}`
`glab auth login {{[-t|--token]}} {{token}}`
- Check authentication status:
@@ -22,4 +22,4 @@ source: https://github.com/tldr-pages/tldr.git
- Log in to a specific GitLab instance:
`glab auth login --hostname {{gitlab.example.com}}`
`glab auth login {{[-h|--hostname]}} {{gitlab.example.com}}`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab issue
> Manage GitLab issues.
> More information: <https://glab.readthedocs.io/en/latest/issue>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/issue/index.md>.
- Display a specific issue:
@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- Display a specific issue in the default web browser:
`glab issue view {{issue_number}} --web`
`glab issue view {{issue_number}} {{[-w|--web]}}`
- Create a new issue in the default web browser:
@@ -22,11 +22,11 @@ source: https://github.com/tldr-pages/tldr.git
- List the last 10 issues with the `bug` label:
`glab issue list --per-page {{10}} --label "{{bug}}"`
`glab issue list {{[-P|--per-page]}} {{10}} {{[-l|--label]}} "{{bug}}"`
- List closed issues made by a specific user:
`glab issue list --closed --author {{username}}`
`glab issue list {{[-c|--closed]}} --author {{username}}`
- Reopen a specific issue:

View File

@@ -7,7 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> Manage GitLab merge requests.
> Some subcommands such as `create` have their own usage documentation.
> More information: <https://glab.readthedocs.io/en/latest/mr>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/mr/index.md>.
- Create a merge request:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab mr create
> Manage GitLab merge requests.
> More information: <https://glab.readthedocs.io/en/latest/mr/create.html>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/mr/create.md>.
- Interactively create a merge request:
@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- Create a merge request, determining the title and description from the commit messages of the current branch:
`glab mr create --fill`
`glab mr create {{[-f|--fill]}}`
- Create a draft merge request:
@@ -22,8 +22,8 @@ source: https://github.com/tldr-pages/tldr.git
- Create a merge request specifying the target branch, title, and description:
`glab mr create --target-branch {{target_branch}} --title "{{title}}" --description "{{description}}"`
`glab mr create {{[-b|--target-branch]}} {{target_branch}} {{[-t|--title]}} "{{title}}" {{[-d|--description]}} "{{description}}"`
- Start opening a merge request in the default web browser:
`glab mr create --web`
`glab mr create {{[-w|--web]}}`

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab mr merge
> Merge GitLab merge requests.
> More information: <https://glab.readthedocs.io/en/latest/mr/merge.html>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/mr/merge.md>.
- Merge the merge request associated with the current branch interactively:
@@ -18,11 +18,11 @@ source: https://github.com/tldr-pages/tldr.git
- Merge the merge request, removing the branch on both the local and the remote:
`glab mr merge --remove-source-branch`
`glab mr merge {{[-d|--remove-source-branch]}}`
- Squash the current merge request into one commit with the message body and merge:
`glab mr merge --squash --message="{{commit_message_body}}"`
`glab mr merge {{[-s|--squash]}} {{[-m|--message]}} "{{commit_message_body}}"`
- Display help:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab pipeline
> List, view, and run GitLab CI/CD pipelines.
> More information: <https://glab.readthedocs.io/en/latest/pipeline>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/index.md>.
- View a running pipeline on the current branch:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab release
> Manage GitLab releases.
> More information: <https://glab.readthedocs.io/en/latest/release>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/release/index.md>.
- List releases in a Gitlab repository, limited to 30 items:

View File

@@ -6,7 +6,7 @@ source: https://github.com/tldr-pages/tldr.git
# glab repo
> Work with GitLab repositories.
> More information: <https://glab.readthedocs.io/en/latest/repo/index.html#synopsis>.
> More information: <https://gitlab.com/gitlab-org/cli/-/blob/main/docs/source/repo/index.md>.
- Create a new repository (if the repository name is not set, the default name will be the name of the current directory):

View File

@@ -7,7 +7,7 @@ source: https://github.com/tldr-pages/tldr.git
> A wrapper for Git that adds commands for working with GitHub-based projects.
> If set up as instructed by `hub alias`, one can use `git` to run `hub` commands.
> More information: <https://hub.github.com>.
> More information: <https://hub.github.com/hub.1.html>.
- Clone a repository using its slug (owners can omit the username):

View File

@@ -10,8 +10,8 @@ source: https://github.com/tldr-pages/tldr.git
- Check the CI status for this branch:
`hub ci-status --verbose`
`hub ci-status {{[-v|--verbose]}}`
- Display status of GitHub checks for a commit:
`hub ci-status --verbose {{commit_SHA}}`
`hub ci-status {{[-v|--verbose]}} {{commit_SHA}}`

View File

@@ -14,4 +14,4 @@ source: https://github.com/tldr-pages/tldr.git
- Create a private repository and open the new repository in a web browser:
`hub create --private --browse`
`hub create {{[-p|--private]}} {{[-o|--browse]}}`

View File

@@ -10,7 +10,7 @@ source: https://github.com/tldr-pages/tldr.git
- List the last 10 issues with the `bug` label:
`hub issue list --limit {{10}} --labels "{{bug}}"`
`hub issue list {{[-L|--limit]}} {{10}} {{[-l|--labels]}} "{{bug}}"`
- Display a specific issue:
@@ -18,4 +18,4 @@ source: https://github.com/tldr-pages/tldr.git
- List 10 closed issues assigneed to a specific user:
`hub issue --state {{closed}} --assignee {{username}} --limit {{10}}`
`hub issue {{[-s|--state]}} {{closed}} {{[-a|--assignee]}} {{username}} --limit {{10}}`

View File

@@ -16,4 +16,4 @@ source: https://github.com/tldr-pages/tldr.git
- Print a file from `stdin` to `stdout`:
`{{wget -O - https://examplewebsite.com/file}} | ippeveps`
`{{wget -O - https://example.com/file}} | ippeveps`

View File

@@ -16,4 +16,4 @@ source: https://github.com/tldr-pages/tldr.git
- Print a file from `stdin` to `stdout`:
`{{wget {{[-O|--output-document]}} - https://examplewebsite.com/file}} | ippeveps`
`{{wget {{[-O|--output-document]}} - https://example.com/file}} | ippeveps`

View File

@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- Remove an `apt` repository:
`apt-add-repository --remove {{repository_spec}}`
`apt-add-repository {{[-r|--remove]}} {{repository_spec}}`
- Update the package cache after adding a repository:
@@ -22,4 +22,4 @@ source: https://github.com/tldr-pages/tldr.git
- Enable source packages:
`apt-add-repository --enable-source {{repository_spec}}`
`apt-add-repository {{[-s|--enable-source]}} {{repository_spec}}`

View File

@@ -22,4 +22,4 @@ source: https://github.com/tldr-pages/tldr.git
- Search for packages that match the `regular_expression`:
`apt-file {{search|find}} --regexp {{regular_expression}}`
`apt-file {{search|find}} {{[-x|--regexp]}} {{regular_expression}}`

View File

@@ -18,7 +18,7 @@ source: https://github.com/tldr-pages/tldr.git
- Show the progress of the check:
`sudo btrfs check --progress {{path/to/partition}}`
`sudo btrfs check {{[-p|--progress]}} {{path/to/partition}}`
- Verify the checksum of each data block (if the filesystem is good):
@@ -26,7 +26,7 @@ source: https://github.com/tldr-pages/tldr.git
- Use the `n`-th superblock (`n` can be 0, 1 or 2):
`sudo btrfs check --super {{n}} {{path/to/partition}}`
`sudo btrfs check {{[-s|--super]}} {{n}} {{path/to/partition}}`
- Rebuild the checksum tree:

View File

@@ -10,11 +10,11 @@ source: https://github.com/tldr-pages/tldr.git
- Add one or more devices to a btrfs filesystem:
`sudo btrfs device add {{path/to/block_device1}} [{{path/to/block_device2}}] {{path/to/btrfs_filesystem}}`
`sudo btrfs device add {{path/to/block_device1 path/to/block_device2 ...}} {{path/to/btrfs_filesystem}}`
- Remove a device from a btrfs filesystem:
`sudo btrfs device remove {{path/to/device|device_id}} [{{...}}]`
`sudo btrfs device remove {{path/to/device1|device_id1 path/to/device2|device_id2 ...}}`
- Display error statistics:
@@ -22,7 +22,7 @@ source: https://github.com/tldr-pages/tldr.git
- Scan all disks and inform the kernel of all detected btrfs filesystems:
`sudo btrfs device scan --all-devices`
`sudo btrfs device scan {{[-d|--all-devices]}}`
- Display detailed per-disk allocation statistics:

View File

@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- Print superblock's and all of its copies' information:
`sudo btrfs inspect-internal dump-super --all {{path/to/partition}}`
`sudo btrfs inspect-internal dump-super {{[-a|--all]}} {{path/to/partition}}`
- Print filesystem's metadata information:

View File

@@ -10,19 +10,19 @@ source: https://github.com/tldr-pages/tldr.git
- Match the sender address using a case-insensitive search:
`exiqgrep -f '<{{email@somedomain.com}}>'`
`exiqgrep -f '<{{email@example.com}}>'`
- Match the sender address and display message IDs only:
`exiqgrep -i -f '<{{email@somedomain.com}}>'`
`exiqgrep -i -f '<{{email@example.com}}>'`
- Match the recipient address:
`exiqgrep -r '{{email@somedomain.com}}'`
`exiqgrep -r '{{email@example.com}}'`
- Remove all messages matching the sender address from the queue:
`exiqgrep -i -f '<{{email@somedomain.com}}>' | xargs exim -Mrm`
`exiqgrep -i -f '<{{email@example.com}}>' | xargs exim -Mrm`
- Test for bounced messages:

View File

@@ -6,36 +6,37 @@ source: https://github.com/tldr-pages/tldr.git
# loadkeys
> Load the kernel keymap for the console.
> See also: `localectl`.
> More information: <https://manned.org/loadkeys>.
- Load a specific keyboard layout for the current console:
`sudo loadkeys {{en|de|fi|dvorak|...}}`
- Load a default keymap:
`loadkeys --default`
- Load default keymap when an unusual keymap is loaded and `-` sign cannot be found:
`loadkeys defmap`
`sudo loadkeys {{[-d|--default]}}`
- Create a kernel source table:
`loadkeys --mktable`
`loadkeys {{[-m|--mktable]}}`
- Create a binary keymap:
`loadkeys --bkeymap`
`loadkeys {{[-b|--bkeymap]}}`
- Search and parse keymap without action:
`loadkeys --parse`
`loadkeys {{[-p|--parse]}}`
- Load the keymap suppressing all output:
`loadkeys --quiet`
`loadkeys {{[-q|--quiet]}}`
- Set a keymap for a specific console:
`sudo loadkeys {{[-C|--console]}} {{/dev/ttyN}} {{uk}}`
- Load a keymap from the specified file for the console:
`loadkeys --console {{/dev/ttyN}} {{/path/to/file}}`
- Use standard names for keymaps of different locales:
`loadkeys --console {{/dev/ttyN}} {{uk}}`
`loadkeys {{[-C|--console]}} {{/dev/ttyN}} {{/path/to/file}}`

View File

@@ -14,4 +14,4 @@ source: https://github.com/tldr-pages/tldr.git
- Additionally print `yes` or `no` to `stdout`:
`systemd-ac-power --verbose`
`systemd-ac-power {{[-v|--verbose]}}`

View File

@@ -18,4 +18,4 @@ source: https://github.com/tldr-pages/tldr.git
- Display the control group hierarchy of one or more systemd units:
`systemd-cgls --unit {{unit1 unit2 ...}}`
`systemd-cgls {{[-u|--unit]}} {{unit1 unit2 ...}}`

View File

@@ -15,11 +15,11 @@ source: https://github.com/tldr-pages/tldr.git
- Change the sort order:
`systemd-cgtop --order={{cpu|memory|path|tasks|io}}`
`systemd-cgtop {{[-i|--order]}} {{cpu|memory|path|tasks|io}}`
- Show the CPU usage by time instead of percentage:
`systemd-cgtop --cpu=percentage`
`systemd-cgtop --cpu percentage`
- Change the update interval in seconds (or one of these time units: `ms`, `us`, `min`):

View File

@@ -10,7 +10,7 @@ source: https://github.com/tldr-pages/tldr.git
- Encrypt a file and set a specific name:
`systemd-creds encrypt --name={{name}} {{path/to/input_file}} {{path/to/output}}`
`systemd-creds encrypt --name {{name}} {{path/to/input_file}} {{path/to/output}}`
- Decrypt the file again:
@@ -18,12 +18,12 @@ source: https://github.com/tldr-pages/tldr.git
- Encrypt text from `stdin`:
`echo -n {{text}} | systemd-creds encrypt --name={{name}} - {{path/to/output}}`
`echo -n {{text}} | systemd-creds encrypt --name {{name}} - {{path/to/output}}`
- Encrypt the text and append it to the service file (the credentials will be available in `$CREDENTIALS_DIRECTORY`):
`echo -n {{text}} | systemd-creds encrypt --name={{name}} --pretty - - >> {{service}}`
`echo -n {{text}} | systemd-creds encrypt --name {{name}} --pretty - - >> {{service}}`
- Create a credential that is only valid until the given timestamp:
`systemd-creds encrypt --not-after="{{timestamp}}" {{path/to/input_file}} {{path/to/output_file}}`
`systemd-creds encrypt --not-after "{{timestamp}}" {{path/to/input_file}} {{path/to/output_file}}`

View File

@@ -14,7 +14,7 @@ source: https://github.com/tldr-pages/tldr.git
- Show only files of specific types (comma-separated list):
`systemd-delta --type {{masked|equivalent|redirected|overridden|extended|unchanged}}`
`systemd-delta {{[-t|--type]}} {{masked|equivalent|redirected|overridden|extended|unchanged}}`
- Show only files whose path starts with the specified prefix (Note: A prefix is a directory containing subdirectories with systemd configuration files):

View File

@@ -18,12 +18,12 @@ source: https://github.com/tldr-pages/tldr.git
- Silently check without printing anything:
`systemd-detect-virt --quiet`
`systemd-detect-virt {{[-q|--quiet]}}`
- Only detect container virtualization:
`systemd-detect-virt --container`
`systemd-detect-virt {{[-c|--container]}}`
- Only detect hardware virtualization:
`systemd-detect-virt --vm`
`systemd-detect-virt {{[-v|--vm]}}`

View File

@@ -14,15 +14,15 @@ source: https://github.com/tldr-pages/tldr.git
- Mount an OS image:
`systemd-dissect --mount {{path/to/image.raw}} {{/mnt/image}}`
`systemd-dissect {{[-m|--mount]}} {{path/to/image.raw}} {{/mnt/image}}`
- Unmount an OS image:
`systemd-dissect --umount {{/mnt/image}}`
`systemd-dissect {{[-u|--umount]}} {{/mnt/image}}`
- List files in an image:
`systemd-dissect --list {{path/to/image.raw}}`
`systemd-dissect {{[-l|--list]}} {{path/to/image.raw}}`
- Attach an OS image to an automatically allocated loopback block device and print its path:

View File

@@ -14,11 +14,11 @@ source: https://github.com/tldr-pages/tldr.git
- Reverse the escaping process:
`systemd-escape --unescape {{text}}`
`systemd-escape {{[-u|--unescape]}} {{text}}`
- Treat the given text as a path:
`systemd-escape --path {{text}}`
`systemd-escape {{[-p|--path]}} {{text}}`
- Append the given suffix to the escaped text:

View File

@@ -10,23 +10,23 @@ source: https://github.com/tldr-pages/tldr.git
- Operate on the specified directory instead of the root directory of the host system:
`sudo systemd-firstboot --root={{path/to/root_directory}}`
`sudo systemd-firstboot --root {{path/to/root_directory}}`
- Set the system keyboard layout:
`sudo systemd-firstboot --keymap={{keymap}}`
`sudo systemd-firstboot --keymap {{keymap}}`
- Set the system hostname:
`sudo systemd-firstboot --hostname={{hostname}}`
`sudo systemd-firstboot --hostname {{hostname}}`
- Set the root user's password:
`sudo systemd-firstboot --root-password={{password}}`
`sudo systemd-firstboot --root-password {{password}}`
- Prompt the user interactively for a specific basic setting:
`sudo systemd-firstboot --prompt={{setting}}`
`sudo systemd-firstboot --prompt {{setting}}`
- Force writing configuration even if the relevant files already exist:

View File

@@ -18,7 +18,7 @@ source: https://github.com/tldr-pages/tldr.git
- Update the binary hardware database, returning a non-zero exit value on any parsing error:
`systemd-hwdb --strict update`
`systemd-hwdb {{[-s|--strict]}} update`
- Update the binary hardware database in `/usr/lib/udev`:
@@ -26,4 +26,4 @@ source: https://github.com/tldr-pages/tldr.git
- Update the binary hardware database in the specified root path:
`systemd-hwdb --root={{path/to/root}} update`
`systemd-hwdb {{[-r|--root]}} {{path/to/root}} update`

View File

@@ -26,4 +26,4 @@ source: https://github.com/tldr-pages/tldr.git
- Generate a new random identifier and print it as a UUID (five groups of digits separated by hyphens):
`systemd-id128 new --uuid`
`systemd-id128 new {{[-u|--uuid]}}`

View File

@@ -15,12 +15,12 @@ source: https://github.com/tldr-pages/tldr.git
- Specify an image policy:
`systemd-machine-id-setup --image-policy={{your_policy}}`
`systemd-machine-id-setup --image-policy {{your_policy}}`
- Display the output as JSON:
`sudo systemd-machine-id-setup --json=pretty`
`sudo systemd-machine-id-setup --json pretty`
- Operate on a disk image instead of a directory tree:
`systemd-machine-id-setup --image={{/path/to/image}}`
`systemd-machine-id-setup --image {{/path/to/image}}`

View File

@@ -22,16 +22,16 @@ source: https://github.com/tldr-pages/tldr.git
- Create an automount point that mounts the actual file system at the time of first access:
`systemd-mount --automount=yes {{path/to/file_or_device}}`
`systemd-mount --automount yes {{path/to/file_or_device}}`
- Unmount one or more devices:
`systemd-mount --umount {{path/to/mount_point_or_device1}} {{path/to/mount_point_or_device2}}`
`systemd-mount {{[-u|--umount]}} {{path/to/mount_point_or_device1}} {{path/to/mount_point_or_device2}}`
- Mount a file system (image or block device) with a specific file system type:
`systemd-mount --type={{file_system_type}} {{path/to/file_or_device}} {{path/to/mount_point}}`
`systemd-mount {{[-t|--type]}} {{file_system_type}} {{path/to/file_or_device}} {{path/to/mount_point}}`
- Mount a file system (image or block device) with additional mount options:
`systemd-mount --options={{mount_options}} {{path/to/file_or_device}} {{path/to/mount_point}}`
`systemd-mount {{[-o|--options]}} {{mount_options}} {{path/to/file_or_device}} {{path/to/mount_point}}`

View File

@@ -19,4 +19,4 @@ source: https://github.com/tldr-pages/tldr.git
- Provide a custom status message to systemd (this information is shown by `systemctl status`):
`systemd-notify --status="{{Add custom status message here...}}"`
`systemd-notify --status "{{Add custom status message here...}}"`

View File

@@ -10,16 +10,16 @@ source: https://github.com/tldr-pages/tldr.git
- Run a command in a container:
`systemd-nspawn --directory {{path/to/container_root}}`
`systemd-nspawn {{[-D|--directory]}} {{path/to/container_root}}`
- Run a full Linux-based OS in a container:
`systemd-nspawn --boot --directory {{path/to/container_root}}`
`systemd-nspawn {{[-b|--boot]}} {{[-D|--directory]}} {{path/to/container_root}}`
- Run the specified command as PID 2 in the container (as opposed to PID 1) using a stub init process:
`systemd-nspawn --directory {{path/to/container_root}} --as-pid2`
`systemd-nspawn {{[-D|--directory]}} {{path/to/container_root}} {{[-a|--as-pid2]}}`
- Specify the machine name and hostname:
`systemd-nspawn --machine={{container_name}} --hostname={{container_host}} --directory {{path/to/container_root}}`
`systemd-nspawn {{[-M|--machine]}} {{container_name}} --hostname {{container_host}} {{[-D|--directory]}} {{path/to/container_root}}`

View File

@@ -16,8 +16,8 @@ source: https://github.com/tldr-pages/tldr.git
- View changes without applying:
`systemd-repart --dry-run=yes`
`systemd-repart --dry-run yes`
- Grow root partition size to 10 gigabytes:
`systemd-repart --size=10G --root /`
`systemd-repart --size 10G --root /`

View File

@@ -18,11 +18,11 @@ source: https://github.com/tldr-pages/tldr.git
- Start a transient service with a custom unit name and description:
`sudo systemd-run --unit={{name}} --description={{string}} {{command}} {{argument1 argument2 ...}}`
`sudo systemd-run {{[-u|--unit]}} {{name}} --description {{string}} {{command}} {{argument1 argument2 ...}}`
- Start a transient service that does not get cleaned up after it terminates with a custom environment variable:
`sudo systemd-run --remain-after-exit --set-env={{name}}={{value}} {{command}} {{argument1 argument2 ...}}`
`sudo systemd-run {{[-r|--remain-after-exit]}} --set-env={{name}}={{value}} {{command}} {{argument1 argument2 ...}}`
- Start a transient timer that periodically runs its transient service (see `man systemd.time` for calendar event format):
@@ -30,12 +30,12 @@ source: https://github.com/tldr-pages/tldr.git
- Share the terminal with the program (allowing interactive input/output) and make sure the execution details remain after the program exits:
`systemd-run --remain-after-exit --pty {{command}}`
`systemd-run {{[-r|--remain-after-exit]}} --pty {{command}}`
- Set properties (e.g. CPUQuota, MemoryMax) of the process and wait until it exits:
`systemd-run --property MemoryMax={{memory_in_bytes}} --property CPUQuota={{percentage_of_CPU_time}}% --wait {{command}}`
`systemd-run {{[-p|--property]}} MemoryMax={{memory_in_bytes}} {{[-p|--property]}} CPUQuota={{percentage_of_CPU_time}}% --wait {{command}}`
- Use the program in a shell pipeline:
`{{command1}} | systemd-run --pipe {{command2}} | {{command3}}`
`{{command1}} | systemd-run {{[-P|--pipe]}} {{command2}} | {{command3}}`

View File

@@ -26,4 +26,4 @@ source: https://github.com/tldr-pages/tldr.git
- Activate a service with a specified port:
`systemd-socket-activate {{path/to/socket.service}} {{{[-l|--listen]}}} {{8080}}`
`systemd-socket-activate {{path/to/socket.service}} {{[-l|--listen]}} {{8080}}`

View File

@@ -19,8 +19,8 @@ source: https://github.com/tldr-pages/tldr.git
- Forward `stdin`/`stdout` to the local system bus within a specific container:
`systemd-stdio-bridge --machine={{mycontainer}}`
`systemd-stdio-bridge {{[-M|--machine]}} {{mycontainer}}`
- Forward `stdin`/`stdout` to a custom D-Bus address:
`systemd-stdio-bridge --bus-path=unix:path={{/custom/dbus/socket}}`
`systemd-stdio-bridge {{[-p|--bus-path]}} unix:path={{/custom/dbus/socket}}`

View File

@@ -19,7 +19,7 @@ source: https://github.com/tldr-pages/tldr.git
- Display help:
`toolbox --help`
`toolbox {{[-h|--help]}}`
- Display version:

View File

@@ -10,20 +10,20 @@ source: https://github.com/tldr-pages/tldr.git
- Create a `toolbox` container for a specific distribution:
`toolbox create --distro {{distribution}}`
`toolbox create {{[-d|--distro]}} {{distribution}}`
- Create a `toolbox` container for a specific release of the current distribution:
`toolbox create --release {{release}}`
`toolbox create {{[-r|--release]}} {{release}}`
- Create a `toolbox` container with a custom image:
`toolbox create --image {{name}}`
`toolbox create {{[-i|--image]}} {{name}}`
- Create a `toolbox` container from a custom Fedora image:
`toolbox create --image {{registry.fedoraproject.org/fedora-toolbox:39}}`
`toolbox create {{[-i|--image]}} {{registry.fedoraproject.org/fedora-toolbox:39}}`
- Create a `toolbox` container using the default image for Fedora 39:
`toolbox create --distro {{fedora}} --release {{f39}}`
`toolbox create {{[-d|--distro]}} {{fedora}} {{[-r|--release]}} {{f39}}`

View File

@@ -11,12 +11,12 @@ source: https://github.com/tldr-pages/tldr.git
- Enter a `toolbox` container using the default image of a specific distribution:
`toolbox enter --distro {{distribution}}`
`toolbox enter {{[-d|--distro]}} {{distribution}}`
- Enter a `toolbox` container using the default image of a specific release of the current distribution:
`toolbox enter --release {{release}}`
`toolbox enter {{[-r|--release]}} {{release}}`
- Enter a toolbox container using the default image for Fedora 39:
`toolbox enter --distro {{fedora}} --release {{f39}}`
`toolbox enter {{[-d|--distro]}} {{fedora}} {{[-r|--release]}} {{f39}}`

Some files were not shown because too many files have changed in this diff Show More