{"id":22045203,"url":"https://github.com/nigelhorne/njh-snippets","last_synced_at":"2026-04-14T18:32:23.553Z","repository":{"id":148208594,"uuid":"118668289","full_name":"nigelhorne/NJH-Snippets","owner":"nigelhorne","description":"Snippets used across many of my programs","archived":false,"fork":false,"pushed_at":"2026-03-16T12:23:39.000Z","size":459,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-03-17T00:49:58.872Z","etag":null,"topics":["c","cookbook","geolocation","perl","perl5","s-record","snippets","snippets-collection"],"latest_commit_sha":null,"homepage":"","language":"Perl","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nigelhorne.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2018-01-23T20:54:01.000Z","updated_at":"2026-03-16T12:23:43.000Z","dependencies_parsed_at":"2023-11-18T23:26:47.044Z","dependency_job_id":"6fd8810d-7106-4585-82d0-7906d4bd4192","html_url":"https://github.com/nigelhorne/NJH-Snippets","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nigelhorne/NJH-Snippets","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FNJH-Snippets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FNJH-Snippets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FNJH-Snippets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FNJH-Snippets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nigelhorne","download_url":"https://codeload.github.com/nigelhorne/NJH-Snippets/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FNJH-Snippets/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31810737,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-14T18:05:02.291Z","status":"ssl_error","status_checked_at":"2026-04-14T18:05:01.765Z","response_time":153,"last_error":"SSL_read: 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":["c","cookbook","geolocation","perl","perl5","s-record","snippets","snippets-collection"],"created_at":"2024-11-30T13:12:14.720Z","updated_at":"2026-04-14T18:32:23.546Z","avatar_url":"https://github.com/nigelhorne.png","language":"Perl","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NJH-Snippets\n\n# SYNOPSIS\n\nCode snippets\n\n## dbpedia\\_location\n\nQuery DBpedia for Geocoding.\nAlso produces OSM HTML.\n\n## eml\\_to\\_clamav\n\nProduce **ClamAV** signatures from emails\n\n## format\n\nShort C program to show the different formatting options with printf.\n\n## geo-free-test\n\nUse addresses in a Gedcom to generate addresses to test Geo::Coder::Free:\n\n## geotag\n\nShow where photographs were taken.\nIt reads the GPS (geotag) information from a JPG and reverse geo-codes it to\nprint the address.\n\n## max\n\nlists the larges files in the current directory tree, sorted by size.\n\n## peek.c\n\nReads input files, converts them to S-records, and sends them \nto a specified destination via TCP, UDP, or a serial port.\nAdditionally,\nit supports outputting the S-records to standard output for debugging or testing.\n\n## server\\_dashboard\n\nThis script creates a web dashboard that monitors the status of a list of web servers.\nIt uses the **Mojolicious** framework to build a simple web interface that shows the server status, HTTP response codes, response time, and color-coded indicators (green for healthy servers, yellow for errors like 404 or 500, and red for unreachable servers).\nThe list of servers to monitor is read from a `servers.txt` file, and the script uses `LWP::UserAgent` to send HTTP requests and check the servers’ availability.\nIt also calculates the response time of each server and assigns a color to the response time, helping to quickly identify slow servers (orange for moderate delays and red for slow responses).\nThe dashboard auto-refreshes every 60 seconds to display up-to-date server status information.\n\nThe script also logs detailed error information into a `server_status.log` file whenever it encounters an unreachable server or HTTP error.\nIt records the timestamp, the URL, the status (e.g., \"Unreachable\" or \"HTTP Error\"), and the error message (e.g., connection refusal or timeout).\nThe logging helps with troubleshooting by providing a history of server failures and errors.\nUsers can filter the dashboard to show only healthy servers or only servers with errors.\nAdditionally, each server URL is clickable, allowing users to directly visit the server’s webpage for more details.\nThis combination of real-time monitoring and logging ensures that users have both a live status overview and a historical log of issues.\n\n## tapechk\n\nVerify a tar or cpio archive written to a device such as a tape drive\n\n## wof-bundle-download\n\nDownload and unpack the latest files from https://dist.whosonfirst.org/bundles/\n\n## wof-sqlite-download\n\nDownload and unpack the latest files from https://dist.whosonfirst.org/sqlite/\n\n## xml2hash\n\nConvert an XML document into a hash\n\n## zlib.c\n\nSample program for the zlib library.\n\n# LICENSE AND COPYRIGHT\n\nCopyright 2015-2025 Nigel Horne.\n\nThis program is released under the following licence: GPL2 for personal use on\na single computer.\nAll other users (for example Commercial, Charity, Educational, Government)\nmust apply in writing for a licence for use from Nigel Horne at `\u003cnjh at nigelhorne.com\u003e`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnigelhorne%2Fnjh-snippets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnigelhorne%2Fnjh-snippets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnigelhorne%2Fnjh-snippets/lists"}