Skip to content

Instantly share code, notes, and snippets.

View disrupted's full-sized avatar

Salomon Popp disrupted

View GitHub Profile
@nullchilly
nullchilly / coc-pylance.md
Last active April 26, 2024 12:20
Add pylance to coc.nvim

Install the pylance extension in vscode or manually download it from the marketplace

The extension path should be similar to this: ~/.vscode/extensions/ms-python.vscode-pylance-2023.11.10

In init.vim, this will automatically detect the latest pylance version because after an upgrade the old plugin might linger for a while:

call coc#config('languageserver', { "pylance": { "module": expand("~/.vscode/extensions/ms-python.vscode-pylance-*/dist/server.bundle.js", 0, 1)[0] } })
# Reconstructed via infocmp from file: /usr/share/terminfo/t/tmux-256color
tmux-256color|tmux with 256 colors,
OTbs, OTpt, am, hs, km, mir, msgr, xenl, AX, G0,
colors#256, cols#80, it#8, lines#24, pairs#32767, U8#1,
acsc=++\,\,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
bel=^G, blink=\E[5m, bold=\E[1m, cbt=\E[Z, civis=\E[?25l,
clear=\E[H\E[J, cnorm=\E[34h\E[?25h, cr=^M,
csr=\E[%i%p1%d;%p2%dr, cub=\E[%p1%dD, cub1=^H,
cud=\E[%p1%dB, cud1=^J, cuf=\E[%p1%dC, cuf1=\E[C,
cup=\E[%i%p1%d;%p2%dH, cuu=\E[%p1%dA, cuu1=\EM,
@jfcherng
jfcherng / st4-changelog.md
Last active April 20, 2024 00:25
Sublime Text 4 changelog just because it's not on the official website yet.
@painor
painor / FastTelethon.py
Last active April 27, 2024 16:21
This will increase the download/upload speed when using telethon
# copied from https://github.com/tulir/mautrix-telegram/blob/master/mautrix_telegram/util/parallel_file_transfer.py
# Copyright (C) 2021 Tulir Asokan
import asyncio
import hashlib
import inspect
import logging
import math
import os
from collections import defaultdict
from typing import Optional, List, AsyncGenerator, Union, Awaitable, DefaultDict, Tuple, BinaryIO
@danmikita
danmikita / init.vim
Created November 16, 2018 19:16
File preview with FZF, RG, Bat, and Devicons
nnoremap <silent> <leader>e :call Fzf_dev()<CR>
" ripgrep
if executable('rg')
let $FZF_DEFAULT_COMMAND = 'rg --files --hidden --follow --glob "!.git/*"'
set grepprg=rg\ --vimgrep
command! -bang -nargs=* Find call fzf#vim#grep('rg --column --line-number --no-heading --fixed-strings --ignore-case --hidden --follow --glob "!.git/*" --color "always" '.shellescape(<q-args>).'| tr -d "\017"', 1, <bang>0)
endif
" Files + devicons
@JonnyWong16
JonnyWong16 / rename_seasons.py
Last active August 28, 2023 17:32
Rename season title for TV shows on Plex.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# Description: Rename season title for TV shows on Plex.
# Author: /u/SwiftPanda16
# Requires: plexapi
from plexapi.server import PlexServer
@kalkih
kalkih / midnight-remake.yaml
Last active March 10, 2020 02:27
Modified midnight theme for Home Assistant
midnight-remake:
# Main colors
primary-color: '#2980b9'
accent-color: '#f1c40f'
dark-primary-color: 'var(--accent-color)'
light-primary-color: 'var(--accent-color)'
# Text colors
primary-text-color: '#ffffff'
text-primary-color: 'var(--primary-text-color)'
@pouyakary
pouyakary / URL
Created August 18, 2018 16:04
Kary Pro Colors - Bare Minimal Dark
pythonista3://?action=add-theme&theme-data=eNqdVs1u2zAMvvcpDO86A7Y7NElv-etlKDDsBQxZZhLNshjIMtasKLCH2BPuSaYfp7YSJ6lnnSzyI_mRFKXXuyAIOcslkYdMMaHC4DEIp8lstUzDz0ZYwIY0XGUKXpxwsppPHp6cUO2aKheE8SxHWYC0CunULKewbZQCmeWElluJjSisRjI3y2lcERVEllkJhxyJtFIlG2hBZzbT2CwH3KBQUc1-gZEksd0TpLK_4VdNNfgmMVgiR1kHf3__CRZEQvDMBKsID1babUuP5AOhL5KFE9ewJ5IolBlnAs642yg2pGL8YGXPIDhG32HbcCKdyjHzV7jUFPdQm-1X_WuygrRWkoltt6d3qSFzWh8rcclQB-4iZIpwRkMrfXNKIeWkri-Y-0TTGSnufYDmW3r6pjuiAijqfDAUFqnZgLSZ8Z1hAR62Ix_13E5js77EHRFtXICMJClYY6NNPbu6UX6i65MBGovZdL1I_Uj2En8AVR7iJFs58sIH7UD7F9soGQezKdZn6UJ47YnzIG2lrrgZquUGZUWUutwfbWansY8zIUe3XfbVzvD_l8n7kZncAS1zfPHp9TbNlBhERAUKuAp777Wj5pktRbY3G1_gac8LPSbddLx8YP0qNoIe7X2wXRSpywGGXd1n9pv2TtRQ8Ga2lICN8q23WihHnK9jgdNxBT5yH3da8oZx3fU3EjcUZoVFw2GEK4pVBUJdKmdslo_4yMA-G5I5R1rqTBGpxh3l9sq-AFrar0XctSjbClkNHGz2uqfAOl2vn-bddaiYagvXfyS8q_cfB2b0Z13nHxPjvQu6V0P_4tfWQNbaFSPcEY0f4kmyCu_e_gG97DQt
@ticky
ticky / mastodon-desktop.user.css
Last active January 1, 2021 22:24
User CSS to make Mastodon behave somewhat more like a native, desktop app. https://cybre.space/@ticky/100530005338444142
.ui {
flex-direction: row;
}
.tabs-bar {
margin: 0;
margin-bottom: 0;
flex-direction: column;
height: auto;
}
@nlinnett
nlinnett / map-card.js
Created June 26, 2018 19:38
Very basic map-card for HomeAssistant/lovelace
import {
LitElement, html
} from 'https://unpkg.com/@polymer/lit-element@^0.5.2/lit-element.js?module';
class MappingCard extends LitElement {
static get properties() {
return {
hass: Object,
config: Object,
}