Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 13 additions & 3 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,18 +39,28 @@ jobs:
uses: actions/checkout@v7

- name: Bootstrap Gentoo repo and profile
# Sync from a daily snapshot tarball, not the live rsync mirror.
# rsync.gentoo.org updates continuously, so a sync that straddles an
# update fetches a metadata manifest that no longer matches the files
# it describes, and portage aborts:
# Manifest mismatch for metadata/md5-cache/Manifest.gz
# __size__: expected: 29048, have: 29060
# That killed this job twice on 2026-09-22 (different file each time)
# after ~47 minutes against a ~2 minute norm. A webrsync snapshot is
# internally consistent by construction and md5/GPG verified, so the
# race cannot occur. Cost: the tree can be up to 24h old, which is
# irrelevant for validating an ebuild.
run: |
mkdir -p /etc/portage/repos.conf
cat > /etc/portage/repos.conf/gentoo.conf <<'EOF'
[gentoo]
location = /var/db/repos/gentoo
sync-type = rsync
sync-uri = rsync://rsync.gentoo.org/gentoo-portage
sync-type = webrsync
auto-sync = yes
EOF

mkdir -p /var/db/repos/gentoo
emerge --sync --quiet
emerge-webrsync --quiet

if [ ! -L /etc/portage/make.profile ]; then
profile_path="$(find /var/db/repos/gentoo/profiles/default/linux/amd64 -type f -name make.defaults | head -n1)"
Expand Down
73 changes: 73 additions & 0 deletions .github/workflows/nix-flake-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
# Copyright (c) 2026 l5yth
# SPDX-License-Identifier: Apache-2.0

# Keeps flake.lock from rotting.
#
# The `nix` job in linux.yml builds against the toolchain pinned in
# flake.lock, which lags the `dtolnay/rust-toolchain@stable` toolchain the
# Rust workflow installs. A dependency that raises its MSRV past the pinned
# rustc therefore breaks `nix` while `Rust` stays green. That is exactly how
# the Linux workflow stayed red for 9 consecutive runs on main in 2026
# (sysinfo 0.39.x requires rustc 1.95; the pin shipped 1.93.0).
#
# This workflow refreshes the pin on a schedule and opens a PR. It does NOT
# run as part of the build: CI always builds the committed lock, never a
# freshly updated one, or the lock would not describe what CI tested.

name: Nix flake update

on:
schedule:
# Thursdays 05:00 UTC. Dependabot's `interval: weekly` default is Monday
# 05:00 UTC, so this deliberately does not share a slot with it: the pin
# moves midweek, after that week's cargo bumps have already landed.
- cron: "0 5 * * 4"
workflow_dispatch:

permissions:
contents: write
pull-requests: write

jobs:
update:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v7

- name: Install Nix
uses: cachix/install-nix-action@v31
with:
extra_nix_config: |
experimental-features = nix-command flakes

- name: Update flake.lock
run: nix flake update

- name: Verify the updated lock builds
# A PR opened with GITHUB_TOKEN does not trigger other workflows, so
# the Linux workflow's `nix` job would not re-run on this PR. Build
# here instead: a lock that does not build never becomes a PR.
run: nix build . --print-build-logs

- name: Open pull request
uses: peter-evans/create-pull-request@v8
with:
branch: l5y-ci-flake-lock
delete-branch: true
commit-message: "chore: update flake.lock"
title: "chore: update flake.lock"
body: |
Automated weekly `nix flake update`.

Verified before opening: `nix build .` succeeded against the
updated lock.

Note that a PR opened with `GITHUB_TOKEN` does not trigger other
workflows, so neither `Linux` nor `Rust` runs on this PR
automatically. The build above is the substitute for the `nix`
job only; it does not cover clippy, rustdoc or coverage. Close
and reopen the PR, or push an empty commit, to get the full
gates before merging.
labels: dependencies
71 changes: 0 additions & 71 deletions CLAUDE.md

This file was deleted.

2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

[package]
name = "psn"
version = "0.1.4"
version = "0.1.5"
edition = "2024"
license = "Apache-2.0"
description = "Terminal UI for process status navigation and control"
Expand Down
15 changes: 5 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,13 @@ Read more: [Dev.to: psn - a minimalist process navigator for Linux](https://dev.

## Dependencies

- GNU/Linux (process data is read from `/proc` via [sysinfo](https://crates.io/crates/sysinfo) — no external binaries required)
- Rust stable toolchain (Rust 2024 edition, Cargo) for building from source
- GNU/Linux. Process data is read from `/proc` via [sysinfo](https://crates.io/crates/sysinfo). No external binaries.
- Rust stable toolchain (Rust 2024 edition, Cargo) for building from source.

Core crates: `ratatui`, `crossterm`, `sysinfo`, `nix`, `anyhow`, `users`.

## Installation

Helpers exist for Arch and Gentoo-based systems but you can install also
via crates.io or from source directly.

### Archlinux

See [PKGBUILD](./packaging/archlinux/PKGBUILD)
Expand All @@ -53,8 +50,6 @@ cargo install psn

### From Source

Build from source:

```bash
git clone https://github.com/l5yth/psn.git
cd psn
Expand All @@ -67,7 +62,7 @@ Run the built binary:
./target/release/psn
```

Or run directly in development:
Run without building a release binary:

```bash
cargo run --release --
Expand All @@ -76,7 +71,7 @@ cargo run --release --
## Usage

```text
psn v0.1.4
psn v0.1.5
process status navigator
apache v2 (c) 2026 l5yth

Expand Down Expand Up @@ -122,7 +117,7 @@ In-app keys:
- `PgUp` / `PgDn`: page up/down
- `←` / `→`: collapse / expand tree node
- `/`: open interactive filter prompt (live, substring match); `Enter` confirms, `Esc` cancels
- `1`..`9`: send corresponding signal to selected process (prompts for confirmation); not available while the filter prompt is open — press `Enter` or `Esc` first
- `1`..`9`: send corresponding signal to selected process (prompts for confirmation). Unavailable while the filter prompt is open; press `Enter` or `Esc` first

## Development

Expand Down
6 changes: 3 additions & 3 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packaging/nix/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

rustPlatform.buildRustPackage {
pname = "psn";
version = "0.1.4";
version = "0.1.5";

src = lib.cleanSource ../..;

Expand Down
Loading