Skip to content

Commit

Permalink
Merge branch 'main' into testing
Browse files Browse the repository at this point in the history
  • Loading branch information
KyleGospo committed Jan 30, 2025
2 parents 1dd424a + 3ea7f67 commit 6f980bb
Show file tree
Hide file tree
Showing 10 changed files with 206 additions and 13 deletions.
11 changes: 0 additions & 11 deletions .github/dependabot.yml

This file was deleted.

1 change: 1 addition & 0 deletions Containerfile
Original file line number Diff line number Diff line change
Expand Up @@ -768,6 +768,7 @@ RUN rm -f /etc/profile.d/toolbox.sh && \
echo "import \"/usr/share/ublue-os/just/84-bazzite-virt.just\"" >> /usr/share/ublue-os/justfile && \
echo "import \"/usr/share/ublue-os/just/85-bazzite-image.just\"" >> /usr/share/ublue-os/justfile && \
echo "import \"/usr/share/ublue-os/just/86-bazzite-windows.just\"" >> /usr/share/ublue-os/justfile && \
echo "import \"/usr/share/ublue-os/just/87-bazzite-framegen.just\"" >> /usr/share/ublue-os/justfile && \
echo "import \"/usr/share/ublue-os/just/90-bazzite-de.just\"" >> /usr/share/ublue-os/justfile && \
if grep -q "kinoite" <<< "${BASE_IMAGE_NAME}"; then \
systemctl enable usr-share-sddm-themes.mount && \
Expand Down
Binary file added press_kit/art/ametrine.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added press_kit/art/character_sheet.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ screens:
default: false
packages:
- Retrieve Decky: sudo -A ujust setup-decky install
Decky Framegen:
description: A Decky plugin that swaps DLSS for FSR 3 Upscaling and Framegen
default: false
packages:
- Retrieve Decky Framegen: sudo -A ujust get-framegen install-decky-plugin
EmuDeck:
description: A utility for installing and configuring emulators on the Steam Deck
default: false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,9 @@ elif [[ ":WIN2:" =~ ":$SYS_ID:" ]]; then
fi
fi

if [[ ":ONEXPLAYER F1:ONEXPLAYER F1L:ONEXPLAYER F1 EVA-01:" =~ ":$SYS_ID:" ]]; then
if [[ ":ONEXPLAYER F1:ONEXPLAYER F1L:ONEXPLAYER F1 EVA-01:ONEXPLAYER X1Pro:" =~ ":$SYS_ID:" ]]; then
if [[ ! $KARGS =~ "video" ]]; then
echo "Adding panel orientation for ONEXPLAYER F1 & ONEXFLY"
echo "Adding panel orientation for ONEXPLAYER F1, ONEXFLY, & X1 Pro"
NEEDED_KARGS+=("--append-if-missing=video=eDP-1:panel_orientation=left_side_up")
fi
if [[ "$(awk '/MemTotal/{print $(NF-1)}' /proc/meminfo)" == "31664740" ]]; then
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,65 @@ toggle-bt-mic:
echo "No changes were made."
fi

# enable or disable wake-on-lan functionality
toggle-wol:
#!/usr/bin/bash
INTERFACE=$(ip link show | awk '/state UP/ {print $2}' | tr -d ':' | grep -E '^(en|eth)')
if [[ -z "$INTERFACE" ]]; then
echo -e "${bold}No active Ethernet interface found.${normal}"
echo "Please ensure your Ethernet connection is enabled or connected."
echo "Exiting without making any changes."
exit 0
fi
CONFIG_FILE="/etc/udev/rules.d/81-wol.rules"
SERVICE_FILE="/etc/systemd/system/force-wol.service"
WOL_STATUS=$(sudo ethtool $INTERFACE | grep "Wake-on" | awk '{print $2}')
CURRENT_STATE="Disabled"
if [[ "$WOL_STATUS" == "g" ]]; then
CURRENT_STATE="Enabled"
fi
echo "Wake-on-LAN is currently: ${bold}${CURRENT_STATE}${normal}"
echo "Enable, Disable Wake-on-LAN, Create Service, or Exit without saving?"
echo "Note: Create service if Enabling is not persistent."
OPTION=$(ugum choose Enable Disable Create-Service Exit)
if [[ "${OPTION,,}" == "enable" ]]; then
echo "You chose to enable Wake-on-LAN."
echo "Requesting root privileges..."
sudo ethtool -s $INTERFACE wol g
if ! grep -q "$INTERFACE" "$CONFIG_FILE" 2>/dev/null; then
echo "Creating udev rule to make this setting persistent..."
echo "ACTION==\"add\", SUBSYSTEM==\"net\", NAME==\"$INTERFACE\", RUN+=\"/usr/bin/ethtool -s \$name wol g\"" | sudo tee "$CONFIG_FILE" > /dev/null
fi
echo "Wake-on-LAN has been ${green}${bold}enabled${normal}."
elif [[ "${OPTION,,}" == "disable" ]]; then
echo "You chose to disable Wake-on-LAN."
echo "Requesting root privileges..."
sudo ethtool -s $INTERFACE wol d
if [[ -f "$CONFIG_FILE" ]]; then
echo "Removing udev rule to disable persistence..."
sudo rm -f "$CONFIG_FILE"
fi
echo "Wake-on-LAN has been ${red}${bold}disabled${normal}."
elif [[ "${OPTION,,}" == "Create-Service" ]]; then
echo "You chose to create a systemd service for enabling WOL at boot."
echo "Requesting root privileges..."
sudo bash -c "cat > $SERVICE_FILE" <<EOF
[Unit]
Description=Force Enable Wake-on-LAN
After=network-online.target
[Service]
Type=oneshot
ExecStart=/sbin/ethtool -s $INTERFACE wol g
[Install]
WantedBy=network-online.target
EOF
sudo systemctl daemon-reload
sudo systemctl enable force-wol.service
echo "Systemd service created and enabled at boot: ${green}${bold}force-wol.service${normal}"
else
echo "No changes were made."
fi

toggle-i915-sleep-fix:
#!/usr/bin/bash
# Explain the purpose of the script
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
# vim: set ft=make :

# Set up DLSS-Enabler Upscaling and Framegen mod. This mod replaces DLSS upscaling and frame generation with FSR3 equivalents in supported games.
get-framegen ACTION="prompt":
#!/usr/bin/bash
source /usr/lib/ujust/ujust.sh
FG_FILES=(
"amd_fidelityfx_dx12.dll" "dlssg_to_fsr3_amd_is_better.dll" "libxess.dll"
"amd_fidelityfx_vk.dll" "dlssg_to_fsr3.ini"
"d3dcompiler_47.dll" "dxgi.dll" "nvapi64.dll"
"DisableNvidiaSignatureChecks.reg" "dxvk.conf" "_nvngx.dll"
"dlss-enabler.dll" "fakenvapi.ini" "nvngx.ini"
"dlss-enabler-upscaler.dll" "fgmod" "nvngx-wrapper.dll"
"dlssg_to_fsr3_amd_is_better-3.0.dll" "fgmod-uninstaller.sh" "RestoreNvidiaSignatureChecks.reg"
)
function check_fgmod_installed() {
FG_DIR="$HOME/fgmod"
if [[ -d "$FG_DIR" ]]; then
for file in "${FG_FILES[@]}"; do
# Check if 'licenses' is a directory
if [[ "$file" == "licenses" ]]; then
if [[ ! -d "$FG_DIR/$file" ]]; then
echo "${yellow}${bold}FGmod is partially installed. 'licenses' is missing or not a directory.${normal}"
return
fi
elif [[ ! -f "$FG_DIR/$file" ]]; then
echo "${yellow}${bold}FGmod is partially installed. Missing file: ${file}${normal}"
return
fi
done
echo "${green}${bold}FGmod is installed and ready to use.${normal}"
else
echo "${red}${bold}FGmod is not installed.${normal}"
fi
}
function check_decky_installed() {
PLUGIN_DIR="$HOME/homebrew/plugins/Decky-Framegen"
if [[ -d "$PLUGIN_DIR" ]]; then
echo "${green}${bold}Decky Framegen plugin is installed.${normal}"
else
echo "${red}${bold}Decky Framegen plugin is not installed.${normal}"
fi
}
OPTION={{ ACTION }}
if [ "$OPTION" == "prompt" ]; then
echo ""
echo "Current Status:"
check_fgmod_installed
echo ""
check_decky_installed
echo ""
echo "${bold}FGmod${normal} enables the replacement of DLSS Upscaling and Framegen with FSR3 equivalents."
echo ""
echo "Below you can install or remove ${bold}FGmod${normal} files,"
echo "or install the ${bold}Decky Framegen${normal} plugin for managing everything conveniently in Game Mode."
echo ""
echo "To patch a Steam game after installation, use the launch option: '~/fgmod/fgmod %COMMAND%'"
echo "To revert changes to the game's files, use: '~/fgmod/fgmod-uninstaller.sh %COMMAND%'"
echo ""
echo "What would you like to do with FGmod?"
echo ""
OPTION=$(ugum choose "Install Decky Framegen plugin" "Install FGmod" "Uninstall FGmod" "Exit without changes")
elif [ "$OPTION" == "help" ]; then
echo "Usage: just get-framegen <option>"
echo " <option>: Specify an action - 'install', 'install-decky-plugin', or 'uninstall'"
echo " Use 'install' to install FGmod."
echo " Use 'install-decky-plugin' to install the Decky Framegen plugin."
echo " Use 'uninstall' to remove FGmod."
exit 0
fi
if [ "${OPTION,,}" == "install" ] || [ "${OPTION,,}" == "install fgmod" ]; then
echo "Installing FGmod..."
TMP_DIR=$(mktemp -d) && cd "$TMP_DIR"
git clone https://github.com/xXJSONDeruloXx/fgmod-bazzite.git .
chmod +x prepare.sh
./prepare.sh
echo "FGmod installed successfully!"
echo "To patch a game, add the launch option '~/fgmod/fgmod %COMMAND%' in its settings."
elif [ "${OPTION,,}" == "install-decky-plugin" ] || [ "${OPTION,,}" == "install decky framegen plugin" ]; then
echo "Installing Decky Framegen plugin..."
API_URL="https://api.github.com/repos/xXJSONDeruloXx/Decky-Framegen/releases/latest"
PLUGIN_URL=$(curl -s "$API_URL" | grep "browser_download_url" | grep ".zip" | cut -d '"' -f 4)

if [ -z "$PLUGIN_URL" ]; then
echo "Failed to fetch the latest Decky Framegen release. Exiting..."
exit 1
fi
PLUGIN_NAME="Decky-Framegen"
PLUGIN_DIR="$HOME/homebrew/plugins"
if [ ! -d "$PLUGIN_DIR" ]; then
echo "Creating plugins directory with sudo..."
sudo mkdir -p "$PLUGIN_DIR"
fi
cd "$PLUGIN_DIR" || { echo "Failed to navigate to plugins directory"; exit 1; }
if [ -d "$PLUGIN_NAME" ]; then
echo "Removing existing $PLUGIN_NAME directory with sudo..."
sudo rm -rf "$PLUGIN_NAME"
fi
echo "Downloading $PLUGIN_NAME from $PLUGIN_URL..."
sudo curl -L -o "${PLUGIN_NAME}.zip" "$PLUGIN_URL"
if [ $? -ne 0 ]; then
echo "Download failed!"
exit 1
fi
echo "Extracting $PLUGIN_NAME..."
sudo unzip -o "${PLUGIN_NAME}.zip" -d .
if [ $? -ne 0 ]; then
echo "Extraction failed!"
exit 1
fi
if [ -d "./${PLUGIN_NAME}/${PLUGIN_NAME}" ]; then
echo "Fixing folder structure..."
sudo mv ./${PLUGIN_NAME}/${PLUGIN_NAME}/* ./${PLUGIN_NAME}/
sudo rm -rf ./${PLUGIN_NAME}/${PLUGIN_NAME}
fi
echo "Cleaning up..."
sudo rm -f "${PLUGIN_NAME}.zip"
echo "$PLUGIN_NAME has been installed successfully to $PLUGIN_DIR!"
echo "Please restart Decky Loader to activate the plugin."
elif [ "${OPTION,,}" == "uninstall" ] || [ "${OPTION,,}" == "uninstall fgmod" ]; then
echo "Uninstalling FGmod..."
if [[ -d "$HOME/fgmod" ]]; then
rm -rf "$HOME/fgmod"
fi
downloads_dir="$HOME/Downloads"
files_to_remove=("prepare.sh" "fgmod.sh" "fgmod-uninstaller.sh")
for file in "${files_to_remove[@]}"; do
if [[ -f "$downloads_dir/$file" ]]; then
rm "$downloads_dir/$file"
fi
done
echo "FGmod removed successfully!"
elif [ "${OPTION,,}" == "exit" ] || [ "${OPTION,,}" == "exit without changes" ]; then
echo "No changes made. Exiting..."
exit 0
else
echo "Invalid option. Exiting..."
exit 1
fi

0 comments on commit 6f980bb

Please sign in to comment.