Fetch and Parse JSON from an API with curl and jq
Learn to make HTTP GET requests to a REST API using `curl`, and efficiently parse the resulting JSON data on the command line using the powerful `jq` tool for data extraction.
Curated list of production-ready BASH scripts and coding solutions.
Learn to make HTTP GET requests to a REST API using `curl`, and efficiently parse the resulting JSON data on the command line using the powerful `jq` tool for data extraction.
Learn to make your Bash scripts more resilient by using `trap` to catch errors and signals, implementing a custom error handler, and logging script execution to a file for better debugging.
A Bash script to efficiently filter large web server access logs by specific IP addresses or HTTP status codes, useful for debugging and analysis.
A simple Bash snippet to parse and load key-value pairs from a .env file into the current shell's environment variables, essential for local development.
A Bash script to quickly start a local HTTP server using Python's http.server and automatically open the served directory in your default web browser.
A Bash script to automate the common Git workflow of creating a new feature branch from the 'development' branch, switching to it, and pushing it to the remote repository.
A Bash script to quickly clear common cache and temporary directories for various web development projects (e.g., Laravel, Node.js builds) to resolve stale data issues.
A Bash script to continuously monitor a website's availability, checking its HTTP status code, and sending an email alert if it's detected as down.
A robust Bash script to automate daily backups of a MySQL or PostgreSQL database, compress the dumps, and manage retention of old backups.
A simple Bash script to efficiently deploy local static website files to a remote server using rsync, ensuring only changed files are transferred.
A simple bash script to automate pulling the latest code from a Git repository and restarting a web service, ideal for basic deployment workflows.
A bash script to efficiently read and process text files line by line, useful for parsing logs, configuration files, or lists of data for web development tasks.