{"id":36236365,"url":"https://github.com/slashdevslashurandom/lockhinter","last_synced_at":"2026-01-11T06:00:29.767Z","repository":{"id":331375970,"uuid":"1126390980","full_name":"slashdevslashurandom/lockhinter","owner":"slashdevslashurandom","description":"Standalone utility to manage logind's LockedHint state","archived":false,"fork":false,"pushed_at":"2026-01-01T20:19:59.000Z","size":9,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-07T05:00:30.441Z","etag":null,"topics":["logind","screenlock","sway","systemd","wayland"],"latest_commit_sha":null,"homepage":"","language":"Rust","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/slashdevslashurandom.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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-01-01T20:14:07.000Z","updated_at":"2026-01-01T20:27:33.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/slashdevslashurandom/lockhinter","commit_stats":null,"previous_names":["slashdevslashurandom/lockhinter"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/slashdevslashurandom/lockhinter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slashdevslashurandom%2Flockhinter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slashdevslashurandom%2Flockhinter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slashdevslashurandom%2Flockhinter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slashdevslashurandom%2Flockhinter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/slashdevslashurandom","download_url":"https://codeload.github.com/slashdevslashurandom/lockhinter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slashdevslashurandom%2Flockhinter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28293188,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-11T04:44:51.577Z","status":"ssl_error","status_checked_at":"2026-01-11T04:44:44.232Z","response_time":60,"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":["logind","screenlock","sway","systemd","wayland"],"created_at":"2026-01-11T06:00:23.235Z","updated_at":"2026-01-11T06:00:29.759Z","avatar_url":"https://github.com/slashdevslashurandom.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# lockhinter, a standalone tool for setting and clearing LockedHint\n\nThis program is a simple tool designed to manage the `LockedHint` state of a\n`logind` session (whether when used as part of `systemd` or a fork, such as\n`elogind`).\n\nNormally, the desktop environment (such as GNOME or Plasma) would set LockedHint\nwhenever a session is locked or unlocked in order to indicate the session's\nstate to the login manager. In addition, certain utilities query that state\nthemselves, usually to make sure that sensitive operations can only be performed\nwhile the session is unlocked.\n\nMore lightweight desktop environments, window managers and Wayland compositors,\nhowever, do not do that, and the session is always treated as if it is\nunlocked. The decision to not add this functionality is usually justified by a\ndesire to not add extra functionality or not add a dependency on `systemd`.\n\nTo solve this problem, `lockhinter` functions as an in-between utility. When\nlaunched with command-line arguments including a locker program's name and its\narguments, `lockhinter` launches the locker, then sets `LockedHint` to true,\nwaiting until the locker terminates. If it terminates gracefully and returns a\ncode of `0` (no errors), `LockedHint` is then set to false, otherwise it is not\nreset. (This is to make sure that `lockhinter` or the locker program crashing\ndoesn't cause the login manager or programs reading `LockedHint` to think a\nsession was unlocked even though it wasn't.)\n\n## Installation\n\nRight now, the best way to install the program is via `cargo`:\n\n`$ cargo install lockhinter`\n\nYou will likely also need to add `$HOME/.cargo/bin` to your `PATH` environment\nvariable, for example by editing the `.profile` file in your home directory to\nsay:\n\n```\nexport PATH=$HOME/.cargo/bin:$PATH\n```\n\nIf any Linux distro maintainers decide to add this utility to their\nrepositories, then installing via package manager will be the preferred way, as\nit would provide a system-wide installation that doesn't require editing\n`$PATH`, as well as automatic updates.\n\n## Usage\n\n`lockhinter` has two modes of operation. The primary one is using it to run\nanother locker utility (such as `swaylock`), in which case it will keep the\n`LockedHint` property set for as long as the locker is running. Parameters for\nrunning the locker should be specified immediately, or after the `--` separator.\n\n```\n$ lockhinter -- swaylock -c 3d3846\n```\n\nor\n\n```\n$ lockhinter swaylock -c 3d3846\n```\n\nBy default, if the `LockedHint` property is already set on a session,\n`lockhinter` will terminate immediately and not change it, but this can be\noverridden with the `-f` or `--force`` parameter:\n\n```\n$ lockhinter -f -- swaylock -c 3d3846\n```\n\nThat way, the program will start the locker again and clear the `LockedHint`\nproperty once the locker closes properly.\n\nIf the `-c` parameter is specified, then `lockhinter` will simply check the\n`LockedHint` property's state, output `FALSE` or `TRUE` to standard output and\nterminate with a code of 0 or 1 respectively.\n\n```\n$ lockhinter -c\nFALSE\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslashdevslashurandom%2Flockhinter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fslashdevslashurandom%2Flockhinter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslashdevslashurandom%2Flockhinter/lists"}