ajust after installing new gpu
This commit is contained in:
parent
0620b3e48f
commit
19b47a2ff7
|
@ -77,4 +77,10 @@
|
|||
<family>IPAGothic</family>
|
||||
</prefer>
|
||||
</alias>
|
||||
<alias>
|
||||
<family>Lucida Console</family>
|
||||
<prefer>
|
||||
<family>monospace</family>
|
||||
</prefer>
|
||||
</alias>
|
||||
</fontconfig>
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
[custom]
|
||||
start=gamemode-start
|
||||
end=gamemode-stop
|
|
@ -27,7 +27,7 @@ context.properties = {
|
|||
|
||||
## Properties for the DSP configuration.
|
||||
#default.clock.rate = 48000
|
||||
default.clock.allowed-rates = [ 44100 :wq48000 ]
|
||||
default.clock.allowed-rates = [ 44100 48000 ]
|
||||
#default.clock.quantum = 1024
|
||||
default.clock.min-quantum = 16
|
||||
#default.clock.max-quantum = 2048
|
||||
|
|
|
@ -1,77 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
client_id='d9c43c00ff914624a02151e43ab5a16c'
|
||||
client_secret=''
|
||||
|
||||
output="$XDG_RUNTIME_DIR/spotify_status"
|
||||
|
||||
token=""
|
||||
get_token() {
|
||||
echo -n 'Bearer '
|
||||
if [[ -z "$token" ]]; then
|
||||
authorization="$(base64 -w 0 <(echo -n "$client_id:$client_secret"))"
|
||||
token="$(curl -s -H "Authorization: Basic $authorization" -d 'grant_type=client_credentials' https://accounts.spotify.com/api/token | jq --join-output --raw-output .access_token)"
|
||||
fi
|
||||
echo -n "$token"
|
||||
}
|
||||
|
||||
track_data=""
|
||||
get_track_data() {
|
||||
if [[ -z "$track_data" ]]; then
|
||||
track_data="$(curl -s -H "Authorization: $(get_token)" "https://api.spotify.com/v1/tracks/$TRACK_ID")"
|
||||
fi
|
||||
echo -n "$track_data"
|
||||
}
|
||||
|
||||
get_artists() {
|
||||
echo "$(get_track_data)" | jq --join-output --raw-output '[.artists[].name] | join(", ")'
|
||||
}
|
||||
|
||||
get_track() {
|
||||
echo "$(get_track_data)" | jq --join-output --raw-output '.name'
|
||||
}
|
||||
|
||||
play() {
|
||||
echo " $(get_track)" >$output
|
||||
echo "$(get_artists) - $(get_track)" >>$output
|
||||
}
|
||||
|
||||
stop() {
|
||||
echo " $(get_track)" >$output
|
||||
echo "$(get_artists) - $(get_track)" >>$output
|
||||
}
|
||||
|
||||
pause() {
|
||||
echo " $(get_track)" >$output
|
||||
echo "$(get_artists) - $(get_track)" >>$output
|
||||
}
|
||||
|
||||
case "$PLAYER_EVENT" in
|
||||
"start")
|
||||
play
|
||||
;;
|
||||
"stop")
|
||||
pause
|
||||
;;
|
||||
"load")
|
||||
;;
|
||||
"play")
|
||||
play
|
||||
;;
|
||||
"pause")
|
||||
pause
|
||||
;;
|
||||
"preload")
|
||||
;;
|
||||
"endoftrack")
|
||||
stop
|
||||
;;
|
||||
"volumeset")
|
||||
;;
|
||||
"change")
|
||||
play
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
[global]
|
||||
username = werhudpj20xndltxqfb95b8dw
|
||||
#password_cmd = pass web/spotify.com | head -n 1
|
||||
use_keyring = true
|
||||
|
||||
backend = pulseaudio
|
||||
#onevent=~/.config/spotifyd/onevent.sh
|
|
@ -91,43 +91,34 @@ output "*" {
|
|||
background ~/.local/share/wallpaper fill
|
||||
}
|
||||
|
||||
# defaults, laptop mode
|
||||
workspace $ws1 output eDP-1
|
||||
workspace $ws2 output eDP-1
|
||||
workspace $ws3 output VGA-1
|
||||
workspace $ws4 output VGA-1
|
||||
workspace $ws5 output VGA-1
|
||||
workspace $ws6 output VGA-1
|
||||
workspace $ws7 output VGA-1
|
||||
workspace $ws8 output VGA-1
|
||||
workspace $ws9 output VGA-1
|
||||
workspace $ws10 output VGA-1
|
||||
|
||||
set $output1 "Goldstar Company Ltd LG QHD 0x00001F95"
|
||||
workspace $ws3 output $output1
|
||||
workspace $ws4 output $output1
|
||||
workspace $ws5 output $output1
|
||||
workspace $ws6 output $output1
|
||||
workspace $ws7 output $output1
|
||||
workspace $ws8 output $output1
|
||||
workspace $ws9 output $output1
|
||||
workspace $ws10 output $output1
|
||||
set $output1 "LG Electronics LG QHD 0x00001F95"
|
||||
workspace $ws3 output $output1 VGA-1
|
||||
workspace $ws4 output $output1 VGA-1
|
||||
workspace $ws5 output $output1 VGA-1
|
||||
workspace $ws6 output $output1 VGA-1
|
||||
workspace $ws7 output $output1 VGA-1
|
||||
workspace $ws8 output $output1 VGA-1
|
||||
workspace $ws9 output $output1 VGA-1
|
||||
workspace $ws10 output $output1 VGA-1
|
||||
output $output1 {
|
||||
# we need to explicitly select the mode, otherwise
|
||||
# sway will select 4k 30Hz
|
||||
position 0 0
|
||||
mode 2560x1440@60Hz
|
||||
adaptive_sync on
|
||||
position 1080 220
|
||||
}
|
||||
|
||||
set $output2 "Ancor Communications Inc ASUS VH238 BALMIB547836"
|
||||
workspace $ws1 output $output2
|
||||
workspace $ws2 output $output2
|
||||
workspace $ws1 output $output2 eDP-1
|
||||
workspace $ws2 output $output2 eDP-1
|
||||
output $output2 {
|
||||
position 0 0
|
||||
position 2560 -270
|
||||
transform 270
|
||||
}
|
||||
|
||||
# Disable this output for consistency when running with discrete GPU enabled
|
||||
output "DP-3" disable
|
||||
|
||||
### Input configuration
|
||||
# mod key
|
||||
set $mod Mod4
|
||||
|
@ -263,16 +254,16 @@ assign [class="^[Dd]iscord$"] $ws1
|
|||
#assign [class="^looking-glass-client$"] $ws3
|
||||
|
||||
# screen
|
||||
workspace $ws1 output HDMI-2
|
||||
workspace $ws2 output HDMI-2
|
||||
workspace $ws3 output HDMI-1
|
||||
workspace $ws4 output HDMI-1
|
||||
workspace $ws5 output HDMI-1
|
||||
workspace $ws6 output HDMI-1
|
||||
workspace $ws7 output HDMI-1
|
||||
workspace $ws8 output HDMI-1
|
||||
workspace $ws9 output HDMI-1
|
||||
workspace $ws10 output HDMI-1
|
||||
# workspace $ws1 output HDMI-A-2
|
||||
# workspace $ws2 output HDMI-A-2
|
||||
# workspace $ws3 output HDMI-A-1
|
||||
# workspace $ws4 output HDMI-A-1
|
||||
# workspace $ws5 output HDMI-A-1
|
||||
# workspace $ws6 output HDMI-A-1
|
||||
# workspace $ws7 output HDMI-A-1
|
||||
# workspace $ws8 output HDMI-A-1
|
||||
# workspace $ws9 output HDMI-A-1
|
||||
# workspace $ws10 output HDMI-A-1
|
||||
|
||||
# reload the configuration file
|
||||
bindsym $mod+Shift+r reload
|
||||
|
@ -333,6 +324,9 @@ exec /bin/dex -a
|
|||
# run a terminal
|
||||
exec $terminal
|
||||
|
||||
# setup outputs
|
||||
exec_always ~/.local/bin/setup-outputs
|
||||
|
||||
bar {
|
||||
swaybar_command waybar
|
||||
}
|
||||
|
|
|
@ -6,8 +6,8 @@ PartOf=graphical-session.target
|
|||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/bin/swayidle -w \
|
||||
timeout 600 'echo RELOADAGENT | gpg-connect-agent; swaylock -f' \
|
||||
timeout 60 'swaymsg "output * dpms off"' \
|
||||
timeout 1200 'echo RELOADAGENT | gpg-connect-agent; swaylock -f' \
|
||||
timeout 600 'swaymsg "output * dpms off"' \
|
||||
resume 'swaymsg "output * dpms on"' \
|
||||
before-sleep 'echo RELOADAGENT | gpg-connect-agent; swaylock -f'
|
||||
|
||||
|
|
|
@ -1,84 +0,0 @@
|
|||
[options]
|
||||
#allow_bold = true
|
||||
#audible_bell = false
|
||||
#clickable_url = true
|
||||
#dynamic_title = true
|
||||
font = Monospace 11
|
||||
font = Hack 11
|
||||
font = Hack Nerd Font 11
|
||||
#fullscreen = true
|
||||
#geometry = 640x480
|
||||
#icon_name = terminal
|
||||
#mouse_autohide = false
|
||||
#scroll_on_output = false
|
||||
#scroll_on_keystroke = true
|
||||
# Length of the scrollback buffer, 0 disabled the scrollback buffer
|
||||
# and setting it to a negative value means "infinite scrollback"
|
||||
scrollback_lines = 10000
|
||||
#search_wrap = true
|
||||
#urgent_on_bell = true
|
||||
hyperlinks = true
|
||||
|
||||
# $BROWSER is used by default if set, with xdg-open as a fallback
|
||||
#browser = xdg-open
|
||||
|
||||
# "system", "on" or "off"
|
||||
#cursor_blink = system
|
||||
|
||||
# "block", "underline" or "ibeam"
|
||||
#cursor_shape = block
|
||||
|
||||
# Hide links that are no longer valid in url select overlay mode
|
||||
#filter_unmatched_urls = true
|
||||
|
||||
# Emit escape sequences for extra modified keys
|
||||
#modify_other_keys = false
|
||||
|
||||
# set size hints for the window
|
||||
#size_hints = false
|
||||
|
||||
# "off", "left" or "right"
|
||||
#scrollbar = off
|
||||
|
||||
[colors]
|
||||
background = rgba(17, 19, 20, 0.85)
|
||||
cursor = #BBBBBB
|
||||
foreground = #EBDBB2
|
||||
|
||||
# black
|
||||
color0 = #2C2F33
|
||||
color8 = #4B5056
|
||||
# red
|
||||
color1 = #B04C50
|
||||
color9 = #B04C50
|
||||
# green
|
||||
color2 = #919652
|
||||
color10 = #94985B
|
||||
# yellow
|
||||
color3 = #E2995C
|
||||
color11 = #E2995C
|
||||
# blue
|
||||
color4 = #66899D
|
||||
color12 = #66899D
|
||||
# magenta
|
||||
color5 = #8D6494
|
||||
color13 = #8D6494
|
||||
# cyan
|
||||
color6 = #527C77
|
||||
color14 = #527C77
|
||||
# white
|
||||
color7 = #A6ABA6
|
||||
color15 = #DDE3DC
|
||||
|
||||
[hints]
|
||||
#font = Monospace 12
|
||||
#foreground = #dcdccc
|
||||
#background = #3f3f3f
|
||||
#active_foreground = #e68080
|
||||
#active_background = #3f3f3f
|
||||
#padding = 2
|
||||
#border = #3f3f3f
|
||||
#border_width = 0.5
|
||||
#roundness = 2.0
|
||||
|
||||
# vim: ft=dosini cms=#%s
|
|
@ -37,7 +37,7 @@ label, button {
|
|||
}
|
||||
|
||||
#idle_inhibitor, #tray, #custom-vpn {
|
||||
padding-right: 0;
|
||||
padding-right: 6px;
|
||||
min-width: 23px;
|
||||
color: white;
|
||||
}
|
||||
|
|
|
@ -1,2 +0,0 @@
|
|||
chooser_type = none
|
||||
output_name = HDMI-A-2
|
|
@ -0,0 +1,7 @@
|
|||
<driconf>
|
||||
<device>
|
||||
<application name="Default">
|
||||
<option name="vblank_mode" value="0" />
|
||||
</application>
|
||||
</device>
|
||||
</driconf>
|
|
@ -0,0 +1,3 @@
|
|||
#!/bin/bash
|
||||
|
||||
systemctl --user stop gammastep
|
|
@ -0,0 +1,3 @@
|
|||
#!/bin/bash
|
||||
|
||||
systemctl --user start gammastep
|
|
@ -1,8 +1,8 @@
|
|||
#!/bin/bash
|
||||
shopt -s nullglob
|
||||
for d in /sys/kernel/iommu_groups/*/devices/*; do
|
||||
n=${d#*/iommu_groups/*}; n=${n%%/*}
|
||||
printf 'IOMMU Group %s ' "$n"
|
||||
lspci -nns "${d##*/}"
|
||||
for g in $(find /sys/kernel/iommu_groups/* -maxdepth 0 -type d | sort -V); do
|
||||
echo "IOMMU Group ${g##*/}:"
|
||||
for d in $g/devices/*; do
|
||||
echo -e "\t$(lspci -nns ${d##*/})"
|
||||
done;
|
||||
done;
|
||||
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
#!/bin/bash
|
||||
|
||||
# find displays with duplicate output
|
||||
# for each displays with duplicate output found, disable the HDMI output
|
||||
# assuming the other output is DisplayPort (prefered)
|
||||
while read -r display_with_dup_output; do
|
||||
while read -r hdmi_output; do
|
||||
# disable the hdmi output
|
||||
swaymsg "output $hdmi_output disable"
|
||||
done < <(swaymsg -t get_outputs | jq --raw-output '.[] | [.name, .make + " " + .model] | @tsv' | grep -E "$display_with_dup_output$" | awk '{print $1}' | grep HDMI) # find the hdmi output
|
||||
done < <(swaymsg -t get_outputs | jq --raw-output '.[] | [.make + " " + .model] | @tsv' | sort | uniq -d) # list all displays with duplicate outputs
|
|
@ -11,6 +11,11 @@ import-gsettings() {
|
|||
eval sed -E $expressions "${XDG_CONFIG_HOME:-$HOME/.config}"/gtk-3.0/settings.ini >/dev/null
|
||||
}
|
||||
|
||||
# list DRM device priority
|
||||
# Set intel graphics as lowest priority
|
||||
# https://github.com/swaywm/sway/wiki#i-have-a-multi-gpu-setup-like-intelnvidia-or-intelamd-and-sway-does-not-start
|
||||
export WLR_DRM_DEVICES="$(drm_info -j | jq --raw-output 'to_entries[] | [if .value.driver.desc == "Intel Graphics" then 1 else 0 end, .key] | @tsv' | awk '{printf "%s:", $2}' | sed -e 's/:$//')"
|
||||
|
||||
export XDG_CURRENT_DESKTOP=sway
|
||||
export XDG_SESSION_TYPE=wayland
|
||||
|
||||
|
|
|
@ -1,2 +1 @@
|
|||
*
|
||||
!.gitignore
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
#/bin/bash
|
||||
#!/bin/bash
|
||||
|
||||
# Autostart sway if we are on tty1
|
||||
if [ -z "$WAYLAND_DISPLAY" ] && [ "$(tty)" = "/dev/tty1" ]; then
|
||||
|
@ -10,4 +10,3 @@ if [ -z "$WAYLAND_DISPLAY" ] && [ "$(tty)" = "/dev/tty1" ]; then
|
|||
|
||||
exec ~/.local/bin/sway 2>"$log_stderr" >"$log_stdout"
|
||||
fi
|
||||
|
|
@ -10,11 +10,10 @@ export PAGER=less
|
|||
export DIFFPROG=meld
|
||||
|
||||
# motd
|
||||
export MOTD_SERVICES="$MOTD_SERVICES docker.socket"
|
||||
export MOTD_SERVICES="$MOTD_SERVICES docker.socket sshd.service"
|
||||
|
||||
# java
|
||||
export _JAVA_OPTIONS="-Dawt.useSystemAAFontSettings=on -Dswing.aatext=true -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel -Dsun.java2d.opengl=true"
|
||||
export JAVA_FONTS=/usr/share/fonts/TTF
|
||||
|
||||
source ~/.local/profile.d/*
|
||||
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
source ~/.config/sway/autostart.sh
|
||||
|
||||
# If you come from bash you might have to change your $PATH.
|
||||
# export PATH=$HOME/bin:/usr/local/bin:$PATH
|
||||
|
||||
|
|
Loading…
Reference in New Issue