Skip to content

Instantly share code, notes, and snippets.

# i3blocks configuration file
#
# The i3blocks man page describes the usage of the binary,
# and its website describes the configuration:
#
# https://vivien.github.io/i3blocks
# Global properties
separator=true
#!/bin/sh
jwq() {
jq -r 'recurse(.nodes[]?) | select(.name == "__i3_scratch").floating_nodes[].'$1', select(.name == "__i3_scratch").floating_nodes[].window_properties.title'
}
app_id=$(swaymsg -t get_tree | jwq app_id | grep -v null)
win_id=$(swaymsg -t get_tree | jwq id | grep -v null)
#!/usr/bin/bash
menu=" Minimize\n Floating Toggle\n Window Shot\n Close"
active=$(swaymsg -t get_tree | jq -r 'recurse(.nodes[]?, .floating_nodes[]?) | select(.focused) | .rect | "\(.x),\(.y)"')
x_cord=$(echo "$active" | cut -d ',' -f 1)
y_cord=$(echo "$active" | sed -e 's/^.*,//g')
selected=$(echo -e $menu | wofi -d -x $(expr $x_cord + 10) -y $(expr $y_cord - 20) -W 10% --prompt="Window Menu" --lines 5 | awk '{print tolower ($2)}')
@lidgnulinux
lidgnulinux / toggle-desktop-sway
Created January 6, 2023 23:06
Toggle desktop for sway.
#!/usr/bin/bash
unminimize () {
swaymsg [app_id='.*'] focus
}
minimize () {
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 6.1.0-rc6 Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="gcc (Debian 12.2.0-9) 12.2.0"
CONFIG_CC_IS_GCC=y
CONFIG_GCC_VERSION=120200
CONFIG_CLANG_VERSION=0
CONFIG_AS_IS_GNU=y
CONFIG_AS_VERSION=23900
/* This stylesheet is generated, DO NOT EDIT */
/* Copyright 2009, 2015 Red Hat, Inc.
*
* Portions adapted from Mx's data/style/default.css
* Copyright 2009 Intel Corporation
*
* This program is free software; you can redistribute it and/or modify it
* under the terms and conditions of the GNU Lesser General Public License,
* version 2.1, as published by the Free Software Foundation.
*
<?xml version="1.0"?>
<!--
This file contains all supported config elements & attributes with
default values.
-->
<labwc_config>
<core>
--- config.def.h.orig 2022-11-01 12:59:11.582373763 +0700
+++ config.def.h 2022-11-01 12:47:54.465483948 +0700
@@ -12,11 +12,12 @@
static const char *tags[] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
static const Rule rules[] = {
- /* app_id title tags mask isfloating monitor */
+ /* app_id title tags mask isfloating monitor x y width height */
/* examples:
{ "Gimp", NULL, 0, 1, -1 },
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 6.0.0-rc7 Kernel Configuration
#
CONFIG_CC_VERSION_TEXT="gcc (Debian 12.2.0-3) 12.2.0"
CONFIG_CC_IS_GCC=y
CONFIG_GCC_VERSION=120200
CONFIG_CLANG_VERSION=0
CONFIG_AS_IS_GNU=y
CONFIG_AS_VERSION=23900
@lidgnulinux
lidgnulinux / Reviewcrux.txt
Created October 2, 2022 00:01
Review crux.
#crux #source_based #distro
Halo,
Kebetulan sedang pengen mencoba distro yg tergolong "source based" dan dari beberapa distro yg ada kami mencoba distro Crux. Perangkat yg kami pakai adalah Laptop Asus Pro 36S.
Berikut ulasan singkatnya.
- Instaler dengan TUI dan CLI.
- Perlu melakukan kompilasi kernel sendiri.
- Durasi kompilasi kernel tergantung spesifikasi perangkat yg dipakai (untuk kami sekitar 20-30 menit).