Skip to content

Instantly share code, notes, and snippets.

View MashukeAlam's full-sized avatar
🌳
Trying to do somethong BiGG

Mashuke Alam Jim MashukeAlam

🌳
Trying to do somethong BiGG
View GitHub Profile
#!/bin/bash
# Function to get the current GNOME theme name
get_current_theme() {
gsettings get org.gnome.desktop.interface gtk-theme | awk -F\' '{print $2}'
}
# Function to toggle between light and dark themes
toggle_theme() {
current_theme=$(get_current_theme)
@MashukeAlam
MashukeAlam / .bash_history
Created November 22, 2023 09:32
setup oracle linux for rubyonrils+oracledb project
sudo dnf update
sudo yum groupinstall 'Development Tools'
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.5/install.sh | bash
source .bashrc
nvm install 14.21
npm i -g yarn
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
@MashukeAlam
MashukeAlam / set_me_up.sh
Last active October 24, 2023 06:46
setup ubuntu
echo "Welcome! Let's set this baby up for your pleasure..."
echo "Remember that this process will require sudo permission."
echo "What is your Full name?"
read git_config_user_name
echo "What is your Github username?"
read username
echo "What email do you want to use to log into Github?"
@MashukeAlam
MashukeAlam / bash.txt
Created October 12, 2023 12:10
bashrc
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
UP add volume 2
DOWN add volume -2
# Player #
border=no
msg-color=yes
msg-module=yes
# OSC/OSD #
osc=yes
osd-bar=yes # Do not remove/comment if mpv_thumbnail_script_client_osc.lua is being used.
osd-font='Cascadia Code' # Set a font for OSC
osd-font-size=22 # Set a font size
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
;==========================================================
;
;
; ██████╗ ██████╗ ██╗ ██╗ ██╗██████╗ █████╗ ██████╗
; ██╔══██╗██╔═══██╗██║ ╚██╗ ██╔╝██╔══██╗██╔══██╗██╔══██╗
; ██████╔╝██║ ██║██║ ╚████╔╝ ██████╔╝███████║██████╔╝
; ██╔═══╝ ██║ ██║██║ ╚██╔╝ ██╔══██╗██╔══██║██╔══██╗
; ██║ ╚██████╔╝███████╗██║ ██████╔╝██║ ██║██║ ██║
; ╚═╝ ╚═════╝ ╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝
;
@MashukeAlam
MashukeAlam / fix_mic_lenovo320.md
Created April 15, 2021 18:37 — forked from Therises/fix_mic_lenovo320.md
Fix microphone on Lenovo IdeaPad 320 on Ubuntu 18.04

In /usr/share/pulseaudio/alsa-mixer/paths/analog-input-internal-mic.conf and /usr/share/pulseaudio/alsa-mixer/paths/analog-input-mic.conf:

  • Under [Element Internal Mic Boost] set volume to zero.
  • Under [Element Int Mic Boost] set volume to zero.
  • Under [Element Mic Boost] set volume to zero

Find your source name from the following command; mine is alsa_input.pci-0000_00_1f.3.analog-stereo

  $ pacmd list-sources | grep 'name:.*input'

Edit /etc/pulse/default.pa and add the following lines, where INPUT_NAME is name of the input source from above step:

# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac