From 63feeb9f369fc6176e85c1c2d8fcc863caad1946 Mon Sep 17 00:00:00 2001 From: Robert Günzler Date: Tue, 10 Feb 2026 12:32:48 +0100 Subject: start new MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Robert Günzler --- bin/modemenu | 34 ---------------------------------- 1 file changed, 34 deletions(-) delete mode 100755 bin/modemenu (limited to 'bin/modemenu') diff --git a/bin/modemenu b/bin/modemenu deleted file mode 100755 index 64ef18e..0000000 --- a/bin/modemenu +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -set -e -[ -n "$DEBUG" ] && set -x - -get_output() { - swaymsg -t get_outputs | - jq -cr '.[] | select(.type=="output") | [.name, .make + " " + .model] | @tsv' | - menu --accept-single | - cut -d $'\t' -f 1 -} - -list_modes() { - local output=$1 - swaymsg -t get_outputs | - jq -cr --arg name "$output" '.[] | select(.type=="output" and .name==$name) | .modes[] | [([.width, "x", .height, "@", .refresh, "Hz"]|join("")), .picture_aspect_ratio // ""] | @tsv' -} - -output=$(get_output) - -mode=$( ( - list_modes "$output" - echo -e "\tset scale..." -) | column -t -s $'\t' | - menu) - -case "$mode" in -*"set scale"*) - scale=$(echo -e "1.0\n1.5\n2.0" | MENU_PROMPT="set scale" menu) - exec swaymsg output "$output" scale "$scale" - ;; -*) - exec swaymsg output "$output" mode "$mode" - ;; -esac -- cgit 1.4.1