Skip to content

Instantly share code, notes, and snippets.

@roycyt
roycyt / init.el
Created September 14, 2017 15:22 — forked from atilaneves/init.el
;;; init.el --- Atila Neves's custom emacs config
;; Copyright (C) 2013
;; Author: <aalvesne@cisco.com>
;; Keywords: init
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
@roycyt
roycyt / gist:6b571c6583ff4af40940ee3fdbf0af4c
Created February 24, 2018 05:34
Qt Creator Segmentation fault
qt-creator-build $ ./bin/qtcreator -version
Qt Creator 4.6.82 based on Qt 5.6.2
# Open https://github.com/mirroring/dhcp/blob/v4_3/server/dhcpd.conf.5
# Then qtcreator crashed.
qt-creator-build $ gdb ./bin/qtcreator
GNU gdb (Ubuntu 7.11.1-0ubuntu1~16.5) 7.11.1
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
@roycyt
roycyt / TrueColour.md
Created August 14, 2018 13:05 — forked from XVilka/TrueColour.md
True Colour (16 million colours) support in various terminal applications and terminals

Colours in terminal

It's a common confusion about terminal colours... Actually we have this:

  • plain ascii
  • ansi escape codes (16 colour codes with bold/italic and background)
  • 256 colour palette (216 colours + 16 ansi + 24 gray) (colors are 24bit)
  • 24bit true colour ("888" colours (aka 16 milion))
printf "\x1b[${bg};2;${red};${green};${blue}m\n"
@roycyt
roycyt / docker-ubuntu.sh
Last active February 10, 2020 09:03
Install Docker CE on the Ubuntu
# https://docs.docker.com/install/linux/docker-ce/ubuntu/
apt update
apt install -y \
apt-transport-https \
ca-certificates \
curl \
gnupg-agent \
software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
add-apt-repository \
@roycyt
roycyt / vimrc
Last active February 12, 2020 05:49
vimrc
unlet! skip_defaults_vim
source $VIMRUNTIME/defaults.vim
if empty(glob('~/.vim/autoload/plug.vim'))
silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs
\ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
endif
call plug#begin('~/.vim/plugged')
@roycyt
roycyt / roy.omp.json
Created August 4, 2023 07:28
roy.omp.json
{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"blocks": [
{
"alignment": "left",
"newline": true,
"segments": [
{
"foreground": "#ffffff",
"style": "plain",