Your coding questions, answered.
Terminus provides developers with solutions and methods to fix common coding issues. Terminus is your resource for precise, actionable insights tailored for professional development environments.
Featured
Vim Find And Replace
You can use either the substitute command or the slash and dot method to search for patterns and replace with different values.
Glory Kim
Select all in Vim / Vi
Select all and copy, paste, or delete the contents
Glory Kim
Searching in Vim
Search forward, backward, case insensitive, and more
Neeran Gul
Git Clone, Push, And Pull Over SSH
Learn how to set up an SSH key to clone, push, and pull a Git repository over the SSH protocol.
Razvan Ludosanu
Undo A Git Pull
How to effectively remove the commits introduced by a pull in Git using git-reset and preserve your local changes using git-stash. Also, how to cancel an unmerged pull request on GitHub.
Glory Kim
Adding a Submodule in Git
This post will show you how to simply add a submodule to a local repository, clone a repository with a submodule, and work within a repository that has a submodule.
Philip Wilkinson
More Articles
171New
A→Z
Learning Docker (The Easy Way) Using LazyDocker & Warp
A concise guide to learning Docker using Lazydocker. Highlights Docker’s benefits and takes advantage of Warp's AI features for a quick setup.
Copy & Paste in Vim / Vi
Copy (Yank), Paste (Put) and Cut (Delete) in Vim
Bash Concatenate Strings
Join two strings together in Bash
Bash Comments
Comments will help make your scripts more readable
Bash printf
How to use string formatting with bash printf
How to Add a User to Sudoers
Grant elevated privileges to users
Bash Case Statement
A popular alternative to the if-then-else statement
Bash Aliases
Create an alias for common commands
Chmod 755
General meaning, examples, and flags for chmod 755
List Installed Packages With Brew
List the installed packages with Homebrew
Reading User Input
Via command line arguments and prompting users for input
Brew Uninstall Package
Remove installed packages with Homebrew
Chmod +X
An overview of chmod +x and how to use it
Chown Recursively
How to recursively change the ownership of files
Copy File To Docker Container
How to copy files and directories from a local machine to a Docker container
Curl Follow Redirect(s)
Learn how to make curl automatically follow a redirect along with the most common pitfalls to avoid when doing so.
Curl Post Request
Use cURL to send data to a server
Curl With Headers
Send request headers with cURL
Curl With Basic Auth
Perform a basic access authentication with cURL
Show Curl Headers
Curl request and response headers
Copy File From Container To Host
Copy files and directories from a Docker container to my local machine
Remove All Docker Images
Learn how to remove all used, unused, and dangling Docker images using the `docker rmi` and `docker image prune` commands.
How to delete lines in Vim / Vi
The best answer depends on which mode you use
Docker Remove Stopped Containers
Remove all stopped Docker containers at once
Run Bash Shell In Docker
Start an interactive shell in Docker container
Run a Shell Script in a Dockerfile
When and how to run a shell script in a Dockerfile
Change Git Origin Remote URL
Learn how to change the remote url of a local git-enabled directory using the git-remote command and Warp's workflow feature.
Amend a Git Commit
Making changes to a previous commit
Git Clone, Push, And Pull Over SSH
Learn how to set up an SSH key to clone, push, and pull a Git repository over the SSH protocol.
How To Create a Git Repository
Creating repos in various scenarios with git
Git Commit History
Different ways to use Git to understand how to navigate the commit history of a repository or branch
Delete Local Git Branch
Learn how to delete local branches from your git repository, including ones with unmerged changes, as well as local remote-tracking branches.
Undoing Git Commits
Explore ways to undo a commit, including git reset, git checkout, and git revert with git while preserving commit history.
Grep Count
Efficiently count lines or occurrences in a file.
Exclude With Grep
Excluding unwanted key terms or directories when using grep
Go To End of File in Vim / Vi
Select and delete to the end of a file in Vim
Grep In a Directory
Learn how to use grep to search for words and phrases within a directory and all its subdirectories, a specific directory, all files, and other variations.
Grep Show Lines Before and After
Learn how to show N lines or all lines before and after the result returned by the `grep` command.
Git Push Tags
This post will show you how to push a single tag, multiple tags, all tags, and tags with commits.
How to run chmod recursively
Using -R is probably not what you want
How to run cron every hour
Along with variations and examples
How to use sudo rm -rf safely
We'll help you understand its components
Grep Across Multiple Lines
Guide on several cases of using grep across multiple lines
Kill a Process in Linux
Strategies for finding and killing processes
Import CSV Into Postgres
Learn your options for how to import a CSV file into a PostgreSQL database and how to resolve the most common errors that may occur when doing so.
Kill Command
Basic syntax and usage of the kill command
Create Folder In GitHub Repository
Learn how to create and push one or more empty directories in a Git repository using `.placeholder` and `README.md` files using both the CLI and the GitHub interface.
mkdir if not exists
Create directories when they don’t already exist
List Installed Npm Packages
Learn how to list globally and locally installed packages with npm, including their dependencies.
How to Make Grep Case Insensitive
By default, grep is case sensitive
How To Use Unix Wildcards
How to use wildcard characters in Linux/Unix commands
Linux File Permissions Explained [Needs Table]
Understand what common expressions like “drwxr xr x” actually mean for a file or directory’s read, write, and execute permissions.
Install NPM Packages From GitHub
Check an npm package version within your project
Import a SQL File in MYSQL
MySQL command line to run an SQL file
Check Npm Package Version
Check an npm package version within your project
How To Reinstall Packages With Npm
Brief guide to reinstalling npm packages using npm
Generate, Sign, and View a CSR With OpenSSL
Learn how to generate, self-sign, and verify certificate signing requests with `openssl`.
How To Run a SQL File With psql
Importing a SQL file into a PostgreSQL database with psql
Delete a File in Python
There are two approaches to deleting a file in Python
Searching in Vim
Search forward, backward, case insensitive, and more
Re-Installing Npm
Learn how to reinstall Node.js and npm on macOS, Linux, and Windows using `curl`, `brew`, `apt`, `nvm`, and Node installer.
Copy File From Remote To Local Using Scp
Copy files and directories from a remote to local
Save Docker Container As Image
Create Docker image from existing container
Removing Directories in Linux
How to remove directories and their content
What Does sudo chown Do?
Why sudo chown is sudo and some common pitfalls
Select all in Vim / Vi
Select all and copy, paste, or delete the contents
Git Push Origin
A breakdown of git push origin
Show & Hide Line Numbers in Vim / Vi
Toggle absolute and relative line numbers
Undo & Redo in Vim / Vi
Keyboard shortcuts and summary of how Vim tracks changes
How To Use sudo su
A quick overview of using sudo su
Undo a Git Rebase
This post will show you how to undo a rebase using git reset, git rebase and git revert
How To Update Yarn
How to update yarn and related troubleshooting
How To Update NPM
Learn how to update npm to a specific version using the npm, nvm, or npx commands.
Vim Go To End/Start of Line
Go to the end or beginning of a line in Vim
Vim / Vi Page Up and Down Controls
Quick reference for Vim's page up and down controls
Go To Line In Vim
Variety of approaches to go to lines
Go To Top of File in Vim
Learn how to jump the top of the file in Vim, then navigate, search, highlight, and delete.
Vim Modes
Learn about seven of Vim’s modes
Upgrade Yarn Package(s)
Learn how to update one or more packages to a specific or latest version using the `yarn upgrade` command.
Verify Certificate With OpenSSL
Learn how to verify local and remote certificates with openssl
Docker Bind Mounts (docker run --volume)
Learn how to mount files and directories into a Docker container using the `docker run --volume` command.
Undo Git Add
Learn how to effectively use 'git add' to stage files in Git for committing, and discover two powerful methods to undo accidental stagings.
Loop Through Files in Directory in Bash
Learn how to iterate over files in a directory linearly and recursively using Bash and Python.
Clear npm Cache
Learn how to clear the npm cache on Linux, macOS, and Windows.
Ignoring SSL Certificate Issues with cURL
Discover how to bypass SSL certificate verification in cURL for HTTPS endpoints, addressing both direct requests and those via proxies. We will also see how this could be handled both in the terminal and system-wide via the `.curlrc` file
Undo a git push
This post will show you had to simply undo a git push three different ways.
Adding a Submodule in Git
This post will show you how to simply add a submodule to a local repository, clone a repository with a submodule, and work within a repository that has a submodule.
Docker Compose Volume: Bind Mounts
Learn how to mount files and directories into a Docker container with Compose using the `compose.yaml` file.
Launch PostgreSQL Using Docker Compose
Learn how to launch and connect a PostgreSQL instance to an application using Docker Compose.
Create Kubernetes Secrets with `kubectl`
Learn how to securely manage sensitive data in your cluster using Kubernetes secrets: from standard key-value pairs, file-based secrets, Docker secrets, TLS certificates, env files, and pod connections.
Remove a Docker Image
Learn how to remove a Docker image locally, on a Docker registry, and on Artifactory.
Install Dev Dependencies With npm
Learn how to install and update dev dependencies using the npm install command.
Execute Packages With npx And npm
Discover the power of npm's npx tool, a developer's best friend for running packages without global installs.
Deleting a Pod with `kubectl`
Learn how to delete a pod in Kubernetes using graceful shutdowns, labels, field selectors, and namespaces.
Create Kubernetes Namespace With `kubectl`
Learn how to create one or more Kubernetes namespaces with `kubectl`.
Restart Kubernetes Pods with kubectl
Learn how to restart Kubernetes pods with kubectl: policies, best practices, rolling restarts, and manual methods.
Removing npm Packages
Learn how to remove packages locally, globally, and from the registry using the npm uninstall command.
Describe Kubernetes Pods With kubectl
Learn how to describe one or more Kubernetes Pods with kubectl.
Upload Files With curl
Learn how to upload a file to FTP, SFTP servers, Artifactory, and AWS S3 using the curl command.
Understand depends_on in Docker Compose
Learn how to express dependencies between services and how to control services startup and shutdown in Docker Compose using the depends_on field.
Delete Kubernetes Deployments With kubectl
Learn how to delete Kubernetes deployments and its associated Pods using the kubectl command.
Perform Rollout Restarts With kubectl
Learn how to perform a rollout restart of Kubernetes Pods with the kubectl command using Deployments, DaemonSets, and StatefulSets.
Execute Commands in Pods With kubectl
Learn how to execute standalone commands and start interactive shell sessions in Pods using the `kubectl exec` command.
How To Copy A Directory In Linux
Learn how to copy directories and their content in Linux using the cp command with options like -r for recursive copying, -i for interactive mode, and -a for preserving attributes.
How To Launch A PostgreSQL Container In Docker
Learn how to launch a PostgreSQL container with Docker and how to connect to it using the command-line interface and pgAdmin.
List Pods With kubectl
Learn how to list and filter Kubernetes Pods by name, namespaces, labels, manifests, and more using the kubectl command.
Set Context With kubectl
Learn how to create, modify, switch, and delete a context in Kubernetes using the kubectl config command.
How to Download Files With curl And wget
Learn how to start and resume the download of files via the HTTP and FTP protocols using the curl and wget commands.
Create Directories Recursively With mkdir
Learn how to recursively create nested directories using the mkdir command, Bash scripts, and Python scripts.
Restart Docker Containers
Learn how to restart Docker containers automatically with restart policies and manually using the docker restart, docker start, docker stop and docker kill commands.
How To Remove Secrets From The Git History Remove Secrets From The Git History
Learn how to remove secrets from the Git history using the BFG and git-filter-repo command-line tools.
Kubernetes vs Docker: The Backbone of Modern Backend Technologies
Lean the fundamentals of the Kubernetes and Docker technologies and how they interplay with each other.
Understanding Port Mapping in Docker Compose
Learn how to set, bind and order ports in Docker Compose using Compose file, IP address, and environment variables.
How To Filter The Output of Commands
Learn how to filter and format the output of commands and logs using the grep, awk, uniq, head, and tail commands.
How To Use An .env File In Docker Compose
Learn how define and pass environment variables to Docker containers using an .env file in Docker Compose.
How To Unzip A tar.gz File
Learn how to unzip a tar.gz file on Linux, macOS, and Windows.
How To List Events With kubectl
Learn how to list and filter events in Kubernetes cluster by namespace, pod name and more using the kubectl command.
Prompt Show Git Branch In Prompt
Enhance your terminal with a custom Git prompt. Learn different ways to integrate this contextual info, from custom shell functions to Warp context chips and toolkits like Starship and P10K.
Compose Create Networks In Docker Compose
Learn how to create, configure, and use networks in Docker Compose.
Tail Container Logs In Docker
Learn how to tail and monitor Docker container logs efficiently to debug, trace, and troubleshoot errors more easily.
Set Docker Container Hostname
Learn how to set, change and match a docker container hostname.
Understand target in Docker Compose
Learn how to build a specific stage in a multi-stage Dockerfile and how to specify target for volumes, configs, secrets and ports.
List Kubernetes Namespaces With kubectl
Learn how to list, describe, customize, sort and filter namespaces in a Kubernetes cluster by name, label, and more using the kubectl command.
Shutdown Services In Docker Compose
Learn how to efficiently shut down your Docker Compose services. This guide covers everything from basic shutdowns to managing volumes and containers.
Manage Docker Networks
Learn how to create, list, connect, disconnect, and delete Docker networks using the docker network command.
Understand healthcheck in Docker Compose
Learn how to check if a service is healthy in Docker Compose using the healthcheck property.
Get Kubernetes Secrets With kubectl
Learn how to list, describe, customize, sort and filter secrets in a Kubernetes cluster by name, type, namespace, label and more using the kubectl command.
Rename A Docker Image
Learn how to rename Docker images locally and remotely using the docker tag command.
Use Cookies With cURL
Learn how to store and send cookies using files, hard-coded values, environment variables with cURL.
Output Logs in Docker Compose
Learn how to output, monitor, customize and filter the logs of the containers related to one or more services in Docker Compose
Create User In Linux
Learn to create and configure user accounts in Linux in interactive and non-interactive mode using the useradd and adduser commands.
Restart Containers In Docker Compose
Learn how to restart and rebuild one or more containers in Docker Compose.
Delete Kubernetes Namespaces With kubectl
Learn how to delete one or more namespaces and their related resources in a Kubernetes cluster using the kubectl command.
Change User Passwords In Linux
Learn how to change, manage and generate user passwords in Linux using the passwd, chpasswd, chage and openssl commands.
Expose Docker Container Ports
Learn how to publish and expose Docker container ports using the docker run command and Dockerfiles.
Get Context In Kubernetes
Learn how to get information about one or more contexts in Kubernetes using the kubectl command.
Execute in a Docker Container
Learn how to execute one or multiple commands in a Docker container using the docker exec command.
Edit Files in Linux
Learn how to edit files in Linux using command-line file editors such as Vim, Nano, and Emacs, the output redirection operator, and the sed command.
List Users In Linux
Learn how to list users and groups in Linux.
Tail Logs In Kubernetes
Learn how to tail and monitor Kubernetes logs efficiently to debug, trace, and troubleshoot errors more easily using the kubectl command.
Launch MySQL Using Docker Compose
Learn how to launch a MySQL container in Docker Compose.
Forward Ports In Kubernetes
Learn how to forward the ports of Kubernetes resources such as Pods and Services using the kubectl port-forward command.
Run SSH In Docker
Learn how to launch and connect to a containerized SSH server in Docker using password-based authentication and SSH keys.
Create Files In Linux
Learn how to create regular files in Linux using command line interface commands like touch, echo, cat, printf, and in-terminal text editors like Vim.
Copy Files In Linux
Learn how to safely and recursively copy one or more files locally and remotely in Linux using the cp and scp command.
Find Files In Linux
Learn how to find and filter files in Linux by owner, size, date, type and content using the find command.
Delete Files In Linux
Learn how to selectively delete files in Linux based on patterns and properties using the rm command.
Remover Users in Linux
Learn how to remove local and remote user accounts and associated groups and files in Linux using the userdel and deluser commands.
Switch Users In Linux
Learn how to switch between users, log in as another user, and execute commands as another user in Linux.
Create Groups In Linux
Learn how to manually and automatically create and list groups in Linux.
Use An .env File In Docker
Learn how to write and use .env files in Docker to populate the environment of containers on startup.
Format Command Output In Linux
Learn how to filter and format the content of files and the output of commands in Linux using the awk command.
Undo a Git Merge
How to rollback the changes introduced by a merge in Git by adding new opposite commits using git-revert and effectively removing commits using git-reset.
Undo A Git Pull
How to effectively remove the commits introduced by a pull in Git using git-reset and preserve your local changes using git-stash. Also, how to cancel an unmerged pull request on GitHub.
How To Run A PSQL File With psql
How to execute multiple SQL statements stored in a file on a specified PostgreSQL database using the psql command. Also, how to handle and fix common errors.
POST JSON Data With Curl
How to send valid HTTP POST requests with JSON data payloads using the curl command and how to avoid common syntax pitfalls. Also, how to solve the HTTP 405 error code.
Vim Find And Replace
You can use either the substitute command or the slash and dot method to search for patterns and replace with different values.
Grep Multiple Strings
How to filter lines and extract specific information from the output of commands or text files based on string patterns and regular expressions with grep.
Get Kubernetes Logs With kubectl
Learn how to get the logs of pods, containers, deployments, and services in Kubernetes using the kubectl command. Troubleshoot a cluster stuck in CrashloopBackoff, ImagePullBackoff, or Pending error states.
Linux Chmod Command
Understand how to use chmod to change the permissions of files and directories. See examples with various chmod options.
How to Check the Size of Folders in Linux
Learn how to output the size of directories and subdirectories in a human-readable format in Linux and macOS using the du command.
Count Files in Linux
Learn how to count files and folders contained in directories and subdirectories in Linux using the ls, find, and wc commands.
List Open Ports in Linux
Learn how to output the list of open TCP and UDP ports in Linux, as well as their IP addresses and ports using the netstat command.
Stop All Docker Containers
How to gracefully shutdown running containers and forcefully kill unresponsive containers with signals in Docker using the docker-stop and docker-kill commands.
Start a Docker Container
Learn how to start a new Docker container from an image in both the foreground and the background using the docker-run command.
The Dockerfile ARG Instruction
Learn how to define and set build-time variables for Docker images using the ARG instruction and the --build-arg flag.
Scale Deployments in Kubernetes
Learn how to manually and automatically scale a Deployment based on CPU usage in Kubernetes using the kubectl-scale and kubectl-autoscale commands.
Copy Files From Pod in Kubernetes
Learn how to copy files and directories from within a Kubernetes Pod into the local filesystem using the kubectl command.
Override the Container Entrypoint With docker run
Learn how to override and customize the entrypoint of a Docker container using the docker run command.
Bash While Loop
Learn how to use and control the while loop in Bash to repeat instructions, and read from the standard input, files, arrays, and more.
Bash If Statement
Learn how to use the if statement in Bash to compare multiple values and expressions.