Skip to content

Instantly share code, notes, and snippets.

View dasdennis's full-sized avatar

Dennis A. Silva dasdennis

  • Concrete
  • São Paulo
View GitHub Profile
#!/usr/bin/env bash
# Taken from (and freely modified as no license was specified):
# https://gist.github.com/ecompayment/b1054421eb90f296bbca226683c7ff7e
# https://gist.github.com/pwnsdx/1217727ca57de2dd2a372afdd7a0fc21
# Before running this script, you must:
# - Disable FileVault (if it is enabled) Note: You will not be able to re-enable FileVault AND keep these customisations.
# - Reboot your Mac into Recovery Mode.
# - Select Terminal from top menu and run the following commands:
@n1snt
n1snt / Oh my ZSH with zsh-autosuggestions zsh-syntax-highlighting zsh-fast-syntax-highlighting and zsh-autocomplete.md
Last active June 28, 2024 15:11
Oh my ZSH with zsh-autosuggestions zsh-syntax-highlighting zsh-fast-syntax-highlighting and zsh-autocomplete.md

Oh my zsh.

Oh My Zsh

Install ZSH.

sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh

Install Oh my ZSH.

-- a partir de quando as statistics estão sendo coletadas and else
-- https://www.postgresql.org/docs/9.2/static/monitoring-stats.html#PG-STAT-DATABASE-VIEW
select stats_reset, datname, to_char(tup_returned*100.0 / (tup_fetched + tup_returned), '90.00%') as pct_tup_returned,
tup_fetched, tup_returned, temp_bytes, tup_inserted, tup_updated, tup_deleted,
xact_commit + xact_rollback as total_transaction, xact_commit, xact_rollback, deadlocks
from pg_stat_database
where datname not like 'template%';
-- statistics about columns
@dasdennis
dasdennis / elementaryos_Juno-customs.sh
Last active October 23, 2019 09:14
Things to do after install elementary OS Juno 5.0
#!/bin/bash
# Download the last version of elementaryOS Juno on https://elementary.io/ free or pay what you want ;)
# Organized by @dennissenner
# Ter Out 30
# Download this script, edit if you want.
# We are not liable for any technical difficulties you may incur arising from the use of these software and hardware.
# Use at your own risk. Please review the code below before using.
# To execute:
# sudo chmod +x -v filename.sh
@ankurk91
ankurk91 / 1-elementary-os-apps.md
Last active December 25, 2023 19:14
elementary OS 5.1 Hera

elementaryOS Apps and Configs

⚠️ No longer maintained! ⚠️

This guide has been updated for elementaryOS v5.0+.

Enbale PPA support

sudo apt-get update
sudo apt-get -y install software-properties-common
@nitanka
nitanka / create-ebs.yml
Last active January 12, 2023 16:40
Ansible: Adding EBS volume to an EC2 instance
---
- name: Creating a Volume
hosts: localhost
become: yes
tasks:
- name: Creating a Volume
ec2_vol:
aws_access_key: "{{ lookup('env', 'AWS_ACCESS_KEY_ID') }}"
aws_secret_key: "{{ lookup('env', 'AWS_SECRET_ACCESS_KEY') }}"
instance: '<instance-id>'
@IronistM
IronistM / setup-elementary.sh
Last active May 8, 2023 18:52 — forked from floriancourgey/setup-elementary.sh
Things to do after installing elementary OS Loki 0.4
#Start with a dist upgrade
sudo apt dist-upgrade
# Get chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i ./google-chrome*.deb
sudo apt-get install -f
# dev (php, docker, git, node, bower, electron, composer)
sudo apt install -y \
@leonardo-lemos
leonardo-lemos / correcao_acentuacao_telegram.md
Last active July 12, 2023 13:32
Como resolver o problema de acentuação do cliente Telegram no elementary OS/Ubuntu 16.04

Para resolver o problema de falta de suporte à acentuação no cliente Telegram no elementary OS, edite o arquivo '~/.local/share/applications/telegramdesktop.desktop' e substitua a seguinte linha:

Exec=/home/[seu_usuario]/Telegram/Telegram -- %u

Por:

Exec=env QT_IM_MODULE=xim /home/[seu_usuario]/Telegram/Telegram -- %u

@evertontrindade
evertontrindade / custom-loki.sh
Last active August 11, 2019 18:50
Things to do after install Elementary OS Loki (0.4)
# First you update your system
sudo apt-get update && sudo apt-get dist-upgrade
# Clean-up System
sudo apt-get purge epiphany-browser epiphany-browser-data #browser
sudo apt-get purge midori-granite #browser
sudo apt-get purge noise
sudo apt-get purge scratch-text-editor #text-editor
sudo apt-get purge modemmanager
sudo apt-get purge geary #email
@victor-torres
victor-torres / uninstall_shell_integration.sh
Created March 1, 2016 12:51
Uninstalling shell integration from iTerm 2
#!/bin/bash
function die() {
echo "${1}"
exit 1
}
which printf > /dev/null 2>&1 || die "Shell integration requires the printf binary to be in your path."
which sed > /dev/null 2>&1 || die "Shell integration requires the sed binary to be in your path."