This commit is contained in:
Shelvacu
2024-10-13 11:25:12 -07:00
parent 3b596662c8
commit c484278721
4 changed files with 65 additions and 59 deletions

View File

@@ -10,7 +10,7 @@ let
colors = vaculib.shellColors;
# thanks colin https://git.uninsane.org/colin/nix-files/src/commit/7f5b2628016c8ca1beec417766157c7676a9c5e5/hosts/common/programs/zsh/starship.nix#L24
x1b = builtins.fromJSON '' "\u001b" ''; # i.e `^[`
x1b = builtins.fromJSON ''"\u001b" ''; # i.e `^[`
set = opt: "${x1b}\\[?${opt}h";
clear = opt: "${x1b}\\[?${opt}l";
reset_without_clear = builtins.concatStringsSep "" [
@@ -28,23 +28,23 @@ let
# `printf '\033[?1000$p'` returns `^[[?1000;2$y` with the `2` indicating it's **unset**.
#
# TODO: unset Line mode and Insert mode?
(clear "1") # Cursor Keys
(clear "1") # Cursor Keys
# (clear "3") # Column Mode (i.e. clear screen/history)
(clear "6") # Origin
(set "7") # Line Wrap
(clear "12") # Blinking Cursor
(set "25") # Show Cursor
(clear "1000") # Report Mouse Clicks
(clear "1002") # Report Cell Mouse Motion
(clear "1003") # Report All Mouse Motion
(clear "1004") # Report Focus In/Out
(clear "1005") # UTF8 Mouse
(clear "1006") # Sgr Mouse
(set "1007") # Alternate Scroll
(set "1042") # Urgency Hints
(clear "6") # Origin
(set "7") # Line Wrap
(clear "12") # Blinking Cursor
(set "25") # Show Cursor
(clear "1000") # Report Mouse Clicks
(clear "1002") # Report Cell Mouse Motion
(clear "1003") # Report All Mouse Motion
(clear "1004") # Report Focus In/Out
(clear "1005") # UTF8 Mouse
(clear "1006") # Sgr Mouse
(set "1007") # Alternate Scroll
(set "1042") # Urgency Hints
# (clear "1049") # Swap Screen And Set Restore Cursor
(clear "2004") # Bracketed Paste
(clear "2026") # Sync Update
(clear "2004") # Bracketed Paste
(clear "2026") # Sync Update
];
# https://man.archlinux.org/man/bash.1#PROMPTING
# \[ and \] begins and ends "a sequence of non-printing characters"

View File

@@ -1,8 +1,8 @@
{ ... }: {
virtualisation.virtualbox.host = {
{ ... }:
{
virtualisation.virtualbox.host = {
enable = true;
enableExtensionPack = true;
};
users.extraGroups.vboxusers.members = [ "shelvacu" ];
}

View File

@@ -2,49 +2,51 @@
lib,
jdk,
gradle_7,
makeWrapper,
stdenv,
fetchFromGitLab,
}:
let
gradle = gradle_7;
self = stdenv.mkDerivation rec {
pname = "bandcamp-collection-downloader";
version = "v2021-12-05";
let
gradle = gradle_7;
self = stdenv.mkDerivation rec {
pname = "bandcamp-collection-downloader";
version = "v2021-12-05";
nativeBuildInputs = [
gradle
makeWrapper
];
nativeBuildInputs = [
gradle
makeWrapper
];
src = fetchFromGitLab {
domain = "framagit.org";
owner = "Ezwen";
repo = "bandcamp-collection-downloader";
rev = version;
hash = "sha256-uvfpTFt92mp4msm06Y/1Ynwx6+DiE+bR8O2dntTzj9I=";
src = fetchFromGitLab {
domain = "framagit.org";
owner = "Ezwen";
repo = "bandcamp-collection-downloader";
rev = version;
hash = "sha256-uvfpTFt92mp4msm06Y/1Ynwx6+DiE+bR8O2dntTzj9I=";
};
mitmCache = gradle.fetchDeps {
pkg = self;
data = ./deps.json;
};
# tests want to talk to bandcamp
doCheck = false;
gradleBuildTask = "fatjar";
installPhase = ''
runHook preInstall
mkdir -p $out/{bin,share/java/bandcamp-collection-downloader}
cp build/libs/bandcamp-collection-downloader.jar $out/share/java/bandcamp-collection-downloader/bandcamp-collection-downloader.jar
makeWrapper ${lib.getExe jdk} $out/bin/bandcamp-collection-downloader \
--add-flags "-jar $out/share/java/bandcamp-collection-downloader/bandcamp-collection-downloader.jar"
runHook postInstall
'';
};
mitmCache = gradle.fetchDeps {
pkg = self;
data = ./deps.json;
};
# tests want to talk to bandcamp
doCheck = false;
gradleBuildTask = "fatjar";
installPhase = ''
runHook preInstall
mkdir -p $out/{bin,share/java/bandcamp-collection-downloader}
cp build/libs/bandcamp-collection-downloader.jar $out/share/java/bandcamp-collection-downloader/bandcamp-collection-downloader.jar
makeWrapper ${lib.getExe jdk} $out/bin/bandcamp-collection-downloader \
--add-flags "-jar $out/share/java/bandcamp-collection-downloader/bandcamp-collection-downloader.jar"
runHook postInstall
'';
}; in self
in
self

View File

@@ -8,7 +8,11 @@
stdenv.mkDerivation rec {
pname = "z3";
version = "4.13.2";
nativeBuildInputs = [ cmake gnumake python3 ];
nativeBuildInputs = [
cmake
gnumake
python3
];
patches = [ ./pkg-config-fix.patch ];