{"id":15857534,"url":"https://github.com/micheleriva/shell-snippets","last_synced_at":"2026-04-29T18:31:43.988Z","repository":{"id":111228757,"uuid":"177808466","full_name":"micheleriva/shell-snippets","owner":"micheleriva","description":"🐚 Little collection of shell scripts and aliases","archived":false,"fork":false,"pushed_at":"2019-03-26T15:01:35.000Z","size":4,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-01T19:49:51.126Z","etag":null,"topics":["bash","bash-script","shell","shell-script"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/micheleriva.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-26T14:44:59.000Z","updated_at":"2022-08-17T12:37:16.000Z","dependencies_parsed_at":"2023-05-31T14:45:43.490Z","dependency_job_id":null,"html_url":"https://github.com/micheleriva/shell-snippets","commit_stats":{"total_commits":4,"total_committers":1,"mean_commits":4.0,"dds":0.0,"last_synced_commit":"1ed6dee4ab8cd3aa3f3b5e188a896be3341febb6"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/micheleriva/shell-snippets","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micheleriva%2Fshell-snippets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micheleriva%2Fshell-snippets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micheleriva%2Fshell-snippets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micheleriva%2Fshell-snippets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/micheleriva","download_url":"https://codeload.github.com/micheleriva/shell-snippets/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/micheleriva%2Fshell-snippets/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32439141,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T18:12:22.909Z","status":"ssl_error","status_checked_at":"2026-04-29T18:11:33.322Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bash","bash-script","shell","shell-script"],"created_at":"2024-10-05T20:23:57.991Z","updated_at":"2026-04-29T18:31:43.973Z","avatar_url":"https://github.com/micheleriva.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e Shell Snippets \u003c/h1\u003e\n\u003cdiv align=\"center\"\u003e Little collection of shell scripts and aliases \u003c/div\u003e\n\n# Getting started\nReady, set, go! Copy and paste `snippets.sh` content into your `.bashrc` or `.zshrc` file and you're ready to go!\n\n**Too lazy?**\nRun the following command in your console and you're up and running!\n\n```sh\nwget https://raw.githubusercontent.com/micheleriva/shell-snippets/copypasta.sh | sh\n```\n\n# Index\n- [Aliases](#aliases)\n  - [Misc](#misc)\n    - [cls](#cls)\n    - [psa](#psa)\n    - [rmf](#rmf)\n  - [Listing](#listing)\n    - [l](#l)\n    - [ll](#ll)\n    - [la](#la)\n    - [lla](#lla)\n    - [ls](#ls)\n  - [Grep](#grep)\n    - [grep](#grep-1)\n  - [Git](#git)\n    - [g](#g)\n    - [gpull](#gpull)\n    - [gpush](#gpush)\n- [Methods](#methods)\n  - [cdb](#cdb)\n  - [mkdircd](#mkdircd)\n  - [runx](#runx)\n\n# Included Snippets\n\n## Aliases\n\n### Misc\n\n#### cls\nClear the console using `cls` instead of `clear`\n```sh\nalias cls=\"clear\"\n```\n\n#### psa\nShorter for `ps aux | grep`\n```sh\nalias psa=\"ps aux | grep\"\n```\n\n#### rmf\nShorter for `sm -rf`\n```sh\nalias rmf=\"rm -rf\"\n```\n\n### Listing\n\n#### l\nShorter for `ls`\n```sh\nalias l=\"ls\"\n```\n\n#### ll\nShorter for `ls -hl`\n```sh\nalias ll=\"ls -hl\"\n```\n\n#### la\nShorter for `ls -A`\n```sh\nalias la=\"ls -A\"\n```\n\n#### lla\nShorter for `ls -alh`\n```sh\nalias lla=\"ls -alh\"\n```\n\n#### ls\nShorter for `ls -Gp`\n```sh\nalias ls=\"ls -Gp\"\n```\n\n### Grep\n\n#### grep\nShorter for `grep --color`\n```sh\nalias grep=\"grep --color\"\n```\n\n### Git\n\n#### g\nShorter for `git`\n```sh\nalias g=\"git\"\n```\n\n#### gpull\nShorter for `git pull \u003ccurrent-branch\u003e`\n```sh\nalias gpull=\"g pull origin $(git_branch_name)\"\n```\n\n#### gpush\nShorter for `git push origin \u003ccurrent-branch\u003e`\n```sh\nalias gpush=\"g push origin $(git_branch_name)\"\n```\n\n## Methods\n\n#### cdb\nCd parent directory `n` times.\n\nExample: `cdb 3` =\u003e `cd ../../../`\n\n```sh\nfunction cdb() {\n  for ((n=0;n\u003c$1;n++))\n    do cd ..\n  done\n}\"\n```\n\n#### mkdircd\nMake new directory and enter it.\n\nExample: `mkdircd foo` =\u003e `mkdircd foo \u0026\u0026 cd foo`\n```sh\nfunction mkdircd() {\n  mkdir $1 \u0026\u0026 cd $1\n}\n```\n\n#### runx\nRun any function multiple times\n\n```sh\nfunction runx() {\n  for ((n=0;n\u003c$1;n++))\n    do ${*:2}\n  done\n}\n```\n\n# License\n[MIT](./LICENSE.md)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicheleriva%2Fshell-snippets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmicheleriva%2Fshell-snippets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmicheleriva%2Fshell-snippets/lists"}