- Configure Gmail in you gitconfig:
[sendemail]
smtpserver = smtp.gmail.com
smtpserverport = 587
smtpencryption = tls
smtpuser = <gmail email address>
from = <email address for From: field>
#!/bin/bash | |
################################################################ | |
# Install a printer on Arch Linux with cups using command line # | |
# Used for a HP PSC 1510 with default driver # | |
################################################################ | |
sudo pacman -S cups | |
sudo systemctl start org.cups.cupsd |
[sendemail]
smtpserver = smtp.gmail.com
smtpserverport = 587
smtpencryption = tls
smtpuser = <gmail email address>
from = <email address for From: field>
$ sudo tlp-stat -s -b | |
--- TLP 1.3.1 -------------------------------------------- | |
+++ System Info | |
System = ASUSTeK COMPUTER INC. 1.0 ZenBook 14 UX410UFR | |
BIOS = UX410UFR.201 | |
Kernel = 5.5.3-arch1-1 #1 SMP PREEMPT Tue, 11 Feb 2020 15:35:41 +0000 x86_64 | |
/proc/cmdline = BOOT_IMAGE=/vmlinuz-linux root=UUID=805eb372-94c7-4e8c-87b4-54b0414fa84a rw loglevel=3 quiet | |
Init system = systemd | |
Boot mode = UEFI |
// compile with `gcc -I/usr/include getxkblayout.c -lX11 -lxkbfile` | |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <X11/XKBlib.h> | |
#include <X11/extensions/XKBrules.h> | |
int main(int argc, char **argv) { | |
Display *dpy = XOpenDisplay(NULL); |
#!/bin/bash | |
# `list_geometry` returns the geometry of the focused of visible windows. You can also get they title | |
# by setting a second argument to `with_description`. The geometry and the title are seperated by `\t`. | |
# | |
# Arguments: | |
# $1: `focused` or `visible` | |
# $2: `with_description` or nothing | |
# | |
# Output examples: |
#!/usr/bin/env bash | |
# Synopsis : Script for installing Nativescript on Ubuntu 16.04 | |
# config parameters | |
CURR_DIR="$PWD" | |
# Start of functions | |
printBanner() { | |
while read; do |
Hello, brethren :-)
As it turns out, the current version of FFmpeg (version 3.1 released earlier today) and libav (master branch) supports full H.264 and HEVC encode in VAAPI on supported hardware that works reliably well to be termed "production-ready".
#!/bin/bash | |
# baraction.sh for spectrwm status bar | |
trap 'update' 5 | |
## DATE | |
dte() { | |
dte="$(date +"%A, %B %d %l:%M%p")" | |
echo -e "$dte" | |
} |
#!/bin/bash | |
TOUCHPAD_ID="$(swaymsg -t get_inputs | grep 'identifier.*Touchpad' | cut -d'"' -f4)" #give me the touchpad identifier | |
STATE="$(swaymsg -t get_inputs | jq .[0].libinput.send_events)" #check if touchpad is enabled | |
[ "$STATE" = '"enabled"' ] && swaymsg input "$TOUCHPAD_ID" events disabled || swaymsg input "$TOUCHPAD_ID" events enabled |
<script> | |
$(document).ready(function () { | |
ConvertNumberToPersion(); | |
}); | |
function ConvertNumberToPersion() { | |
persian = { 0: '۰', 1: '۱', 2: '۲', 3: '۳', 4: '۴', 5: '۵', 6: '۶', 7: '۷', 8: '۸', 9: '۹' }; | |
function traverse(el) { |