{"id":44712465,"url":"https://github.com/szazeski/checkfreespace","last_synced_at":"2026-02-15T12:47:56.145Z","repository":{"id":64303368,"uuid":"300037315","full_name":"szazeski/checkfreespace","owner":"szazeski","description":"cross platform simple command line tool to check remaining disk space that is CI continuous integration friendly","archived":false,"fork":false,"pushed_at":"2024-07-21T00:29:23.000Z","size":30,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-07-21T01:33:45.835Z","etag":null,"topics":["cli","devops-tools","golang","sysadmin-tool"],"latest_commit_sha":null,"homepage":"https://www.checkcli.com","language":"Go","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/szazeski.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}},"created_at":"2020-09-30T19:28:28.000Z","updated_at":"2024-07-21T00:29:30.000Z","dependencies_parsed_at":"2024-01-14T04:25:47.179Z","dependency_job_id":"62e4ea94-56c7-4328-bd9b-ffdde239e099","html_url":"https://github.com/szazeski/checkfreespace","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/szazeski/checkfreespace","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/szazeski%2Fcheckfreespace","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/szazeski%2Fcheckfreespace/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/szazeski%2Fcheckfreespace/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/szazeski%2Fcheckfreespace/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/szazeski","download_url":"https://codeload.github.com/szazeski/checkfreespace/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/szazeski%2Fcheckfreespace/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29478360,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-15T11:35:25.641Z","status":"ssl_error","status_checked_at":"2026-02-15T11:34:57.128Z","response_time":118,"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":["cli","devops-tools","golang","sysadmin-tool"],"created_at":"2026-02-15T12:47:52.954Z","updated_at":"2026-02-15T12:47:56.140Z","avatar_url":"https://github.com/szazeski.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# checkfreespace\r\na simple command line tool that checks the root of the system to see if it has 10% free disk space, if not it returns exit code 2 allowing CI to fail the build.\r\n\r\n`checkfreespace`\r\n```\r\n/ on docker\r\n Free:    149 GB / 227 GB\r\n Percent: 65.64%\r\n[PASS] Disk OK\r\n```\r\n\r\n`checkfreespace -gb 50`\r\n```\r\n/ on M1.lan\r\n Free:    24.6 GB / 228 GB\r\n Percent: 10.79%\r\n[FAIL] Free disk space under 50.0GB\r\n```\r\n(exit code 2)\r\n\r\n## Options\r\n\r\n `-help` gets you the available options and version\r\n\r\n `-gb 1.5` sets the pass rate if the system has at least 1.5GB of free space\r\n\r\n `-percent 2.5` sets the pass rate to 2.5% free *(default is 10%)*\r\n\r\n `-json` converts output to json format:\r\n`{\"Filesystem\":\"\",\"TotalGb\":227,\"FreeGb\":149,\"FreePercentage\":65.63876651982379,\"Hostname\":\"docker\",\"Status\":\"[PASS] Disk OK\",\"Passed\":true}`\r\n\r\n `-path /` optionally overrides the default path to check free space on such as `/mnt/usbdrive` or `D:`\r\n\r\n## Installation\r\n\r\n\r\n### Mac Homebrew\r\n\r\n`brew install szazeski/tap/checkfreespace`\r\n\r\n### Linux (and mac too)\r\n\r\n```\r\nwget https://github.com/szazeski/checkfreespace/releases/download/v1.0.3/checkfreespace_1.0.3_$(uname -s)_$(uname -m).tar.gz -O checkfreespace.tar.gz \u0026\u0026 tar -xf checkfreespace.tar.gz \u0026\u0026 chmod +x checkfreespace \u0026\u0026 sudo mv checkfreespace /usr/bin/\r\n```\r\n\r\n### Windows (Powershell)\r\n\r\n```\r\nInvoke-WebRequest https://github.com/szazeski/checkfreespace/releases/download/v1.0.3/checkfreespace_1.0.3_Windows_x86_64.zip -outfile checkfreespace.zip; Expand-Archive checkfreespace.zip; echo \"if you want, move the file to a PATH directory like WINDOWS folder\"\r\n```\r\n\r\nthen move to `C:\\Windows\\` or other PATH directory\r\n\r\n# Syscall Issues\r\n- Windows doesn't have `syscall.Statfs`, makes a kernel32.dll call instead.\r\n- Mac has `syscall.Statfs_t.Fstypename` but linux and windows doesn't. It returns the partition type like `apfs`, currently the app just returns a blank string for filesystem.\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fszazeski%2Fcheckfreespace","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fszazeski%2Fcheckfreespace","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fszazeski%2Fcheckfreespace/lists"}