{"id":28795905,"url":"https://github.com/sofilip/scripts","last_synced_at":"2026-05-02T05:31:52.288Z","repository":{"id":299301559,"uuid":"1002324912","full_name":"sofilip/scripts","owner":"sofilip","description":"A collection of Bash scripts for everyday Linux tasks including directory backups, log monitoring, system diagnostics, and file organization. Designed to be simple, efficient, and user-friendly.","archived":false,"fork":false,"pushed_at":"2025-06-15T20:15:29.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-15T21:46:59.223Z","etag":null,"topics":["bash","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":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sofilip.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2025-06-15T08:09:14.000Z","updated_at":"2025-06-15T21:06:38.000Z","dependencies_parsed_at":"2025-06-15T21:47:02.176Z","dependency_job_id":"41620d15-0211-4acc-b683-2bb972a7533c","html_url":"https://github.com/sofilip/scripts","commit_stats":null,"previous_names":["sofilip/scripts"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/sofilip/scripts","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sofilip%2Fscripts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sofilip%2Fscripts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sofilip%2Fscripts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sofilip%2Fscripts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sofilip","download_url":"https://codeload.github.com/sofilip/scripts/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sofilip%2Fscripts/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260477932,"owners_count":23015066,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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","shell","shell-script"],"created_at":"2025-06-18T03:10:42.416Z","updated_at":"2026-05-02T05:31:52.283Z","avatar_url":"https://github.com/sofilip.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# Shell Scripts Toolkit\n\nThis repository includes four Bash scripts designed for Linux system automation and monitoring tasks. Each script is interactive and user-friendly.\n\n---\n\n## 1. `backup_script.sh`\n\nCreates a compressed backup of a specified directory.\n\n### Features:\n- Prompts the user for the full path of the directory to back up.\n- Validates that the directory exists and is readable.\n- Creates a gzip-compressed `.tar.gz` file in `~/backups/`, named like:  \n  `backup_\u003cdir_name\u003e_YYYYMMDD_HHMMSS.tar.gz`\n- Retains only the last 7 backups; older ones are automatically deleted.\n- Notifies the user about success or any errors.\n\n---\n\n## 2. `log_monitor.sh`\n\nMonitors log files for important entries.\n\n### Features:\n- Prompts the user for the full path of a system log file (e.g. `/var/log/syslog`).\n- Searches for entries containing keywords: `error`, `warning`, `critical` (case-insensitive).\n- Saves matching lines into a report file:  \n  `~/important_\u003clog_name\u003e_\u003cdate\u003e.log`\n- If no matches are found, the report is not created.\n- Automatically deletes report files older than 7 days.\n- Displays the number of matches and a preview (first 5 lines).\n\n---\n\n## 3. `system_info.sh`\n\nDisplays system and hardware information in a formatted output.\n\n### Features:\n- Shows current date/time, hostname, user.\n- Displays CPU/RAM usage and disk space.\n- Lists:\n  - OS name, kernel version, uptime\n  - Number of installed packages\n  - Desktop environment and window manager (if available)\n  - Top 5 processes by CPU and RAM usage\n- Uses color-coded output for clarity.\n\n---\n\n## 4. `organize_by_extension.sh`\n\nOrganizes files in a specified directory based on file extension.\n\n### Features:\n- Accepts a directory as input.\n- Validates the directory’s existence.\n- Creates subfolders for each unique file extension.\n- Moves files into corresponding subfolders (e.g. `.txt` → `txt/`).\n- Files without extensions go into a `no_extension/` folder.\n- Displays informative messages during the organization process.\n\n---\n\n## Usage\n\nEach script is executable. Make sure to give execute permissions:\n\n```bash\nchmod +x script_name.sh\n```\n\nThen run:\n\n```bash\n./script_name.sh\n```\n\nFor `organize_by_extension.sh`, provide the directory as an argument:\n\n```bash\n./organize_by_extension.sh /path/to/your/folder\n```\n\n---\n\n## Requirements\n\n- Bash shell (typically preinstalled on most Linux distros)\n- Standard GNU utilities (`tar`, `find`, `grep`, `df`, `ps`, etc.)\n\nCourse: Operating Systems - Unix\n\nInstitution: University of Piraeus\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsofilip%2Fscripts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsofilip%2Fscripts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsofilip%2Fscripts/lists"}