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
14 changes: 11 additions & 3 deletions .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -141,16 +141,24 @@ jobs:
run: |
cargo set-version ${{ steps.changelog.outputs.version }}
cargo build --verbose
- name: 🛠️ Update flake.nix version to match Cargo.toml
if: steps.changelog.outputs.skipped == 'false'
run: |
VERSION="${{ steps.changelog.outputs.version }}"
# Update version in flake.nix - matches pattern: version = "X.Y.Z";
sed -i "s/version = \"[0-9]*\.[0-9]*\.[0-9]*\";/version = \"${VERSION}\";/" flake.nix
# Verify the update
grep "version = " flake.nix | head -1
- name: 🛠️ Update lockfile
if: steps.changelog.outputs.skipped == 'false'
run: cargo update
- name: 🛠️ Commit Cargo.lock
- name: 🛠️ Commit Cargo.lock, Cargo.toml, and flake.nix
if: steps.changelog.outputs.skipped == 'false'
run: |
git config user.name "chess-seventh"
git config user.email "[email protected]"
git add Cargo.lock Cargo.toml
git commit -m "chore: update Cargo.lock and Cargo.toml [skip ci]"
git add Cargo.lock Cargo.toml flake.nix
git commit -m "chore: update Cargo.lock, Cargo.toml, and flake.nix [skip ci]"
git push
- name: ✨ Create Release
if: steps.changelog.outputs.skipped == 'false'
Expand Down
5 changes: 4 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,11 @@ env_logger = "0.11.8"
tempfile = "3.23"
chrono = {version = "0.4.42", features = ["serde"]}

[lib]
doctest = false

[package]
name = "rusty-commit-saver"
version = "4.5.0"
edition = "2024"
edition = "2021"
authors = ["chess7th"]
22 changes: 11 additions & 11 deletions devenv.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
"devenv": {
"locked": {
"dir": "src/modules",
"lastModified": 1764082355,
"lastModified": 1764227073,
"owner": "cachix",
"repo": "devenv",
"rev": "42c2bdc468814a18a81eb19df79c47929b298b1b",
"rev": "ee868b9986b84b82fee40ecc2524340d4a154961",
"type": "github"
},
"original": {
Expand Down Expand Up @@ -106,10 +106,10 @@
},
"nixpkgs_2": {
"locked": {
"lastModified": 1763934636,
"lastModified": 1764167966,
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "ee09932cedcef15aaf476f9343d1dea2cb77e261",
"rev": "5c46f3bd98147c8d82366df95bbef2cab3a967ea",
"type": "github"
},
"original": {
Expand Down Expand Up @@ -138,10 +138,10 @@
]
},
"locked": {
"lastModified": 1764038373,
"lastModified": 1764211126,
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "ab3536fe850211a96673c6ffb2cb88aab8071cc9",
"rev": "895935bff08cfcfb663fb9c8263c43596e7cd1ed",
"type": "github"
},
"original": {
Expand All @@ -155,10 +155,10 @@
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1757989933,
"lastModified": 1764038373,
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "8249aa3442fb9b45e615a35f39eca2fe5510d7c3",
"rev": "ab3536fe850211a96673c6ffb2cb88aab8071cc9",
"type": "github"
},
"original": {
Expand All @@ -176,15 +176,15 @@
"rust-overlay": "rust-overlay_2"
},
"locked": {
"lastModified": 1764115189,
"lastModified": 1764089152,
"owner": "chess-seventh",
"repo": "rusty-commit-saver",
"rev": "982216f44cbd22e8be972da8fcaa5c9c7b6bedd5",
"rev": "cc0bf19ae14b04901be5ee654df30733484fffae",
"type": "github"
},
"original": {
"owner": "chess-seventh",
"ref": "HEAD",
"ref": "v4.0.0",
"repo": "rusty-commit-saver",
"type": "github"
}
Expand Down
2 changes: 1 addition & 1 deletion devenv.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ inputs:
nixpkgs:
follows: nixpkgs
rusty-commit-saver:
url: github:chess-seventh/rusty-commit-saver?ref=HEAD
url: github:chess-seventh/rusty-commit-saver?ref=v4.0.0
inputs:
nixpkgs:
follows: nixpkgs
Expand Down
28 changes: 13 additions & 15 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
overlays = [ (import rust-overlay) ];
pkgs = import nixpkgs { inherit system overlays; };

rustVersion = pkgs.rust-bin.nightly."1.89.0".default;
# Use nightly to match your devenv.nix
rustVersion = pkgs.rust-bin.nightly.latest.default;

rustPlatform = pkgs.makeRustPlatform {
cargo = rustVersion;
Expand All @@ -23,34 +24,31 @@
in {
packages.default = rustPlatform.buildRustPackage {
pname = "rusty-commit-saver";
version = "4.4.0";
version = "4.5.0";
src = ./.;
cargoLock.lockFile = ./Cargo.lock;

nativeBuildInputs = with pkgs;
[
pkg-config # Essential for finding OpenSSL
];
nativeBuildInputs = with pkgs; [ pkg-config ];
buildInputs = with pkgs; [ openssl openssl.dev ];

buildInputs = with pkgs; [
openssl # OpenSSL library
openssl.dev # OpenSSL development headers
];

# Environment variables to help find OpenSSL
OPENSSL_NO_VENDOR = 1; # Use system OpenSSL instead of vendored
OPENSSL_NO_VENDOR = 1;
PKG_CONFIG_PATH = "${pkgs.openssl.dev}/lib/pkgconfig";

# Doctests are now marked ignore, so doCheck works fine
doCheck = true;
};

# Development shell
devShells.default = pkgs.mkShell {
buildInputs = with pkgs; [
(rustVersion.override { extensions = [ "rust-src" ]; })
(pkgs.rust-bin.nightly.latest.default.override {
extensions = [ "rust-src" ];
})
cargo
rustc
pkg-config
openssl
openssl.dev
git
];

PKG_CONFIG_PATH = "${pkgs.openssl.dev}/lib/pkgconfig";
Expand Down
Loading