This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Labels required: Review/Discard, Review/Keep, Kept | |
// Gmail's importance markers should be turned on | |
// Star a message to signal it's important | |
// (NOTE: messages will be automatically unstarred after treatment, e.g., after being auto-removed from Review/Discard) | |
/* tidyInbox.gs (run every 15 minutes) */ | |
function tidyInbox() { | |
// Apply label "Kept" to starred threads with label "Review/Keep" | |
label('Kept').addToThreads(find('is:starred label:Review/Keep')); |
This is a cheat sheet for how to perform various actions to ZSH, which can be tricky to find on the web as the syntax is not intuitive and it is generally not very well-documented.
Description | Syntax |
---|---|
Get the length of a string | ${#VARNAME} |
Get a single character | ${VARNAME[index]} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"statusline setup | |
set statusline=%f "tail of the filename | |
"display a warning if fileformat isnt unix | |
set statusline+=%#warningmsg# | |
set statusline+=%{&ff!='unix'?'['.&ff.']':''} | |
set statusline+=%* | |
"display a warning if file encoding isnt utf-8 | |
set statusline+=%#warningmsg# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ------------------------------------------------------------------------------ | |
# tlp - Parameters for power saving | |
# See full explanation: http://linrunner.de/en/tlp/docs/tlp-configuration.html | |
# dir: /etc/default/tlp | |
# Hint: some features are disabled by default, remove the leading # to enable | |
# them. | |
# Set to 0 to disable, 1 to enable TLP. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Edit this configuration file to define what should be installed on | |
# your system. Help is available in the configuration.nix(5) man page | |
# and in the NixOS manual (accessible by running ‘nixos-help’). | |
{ config, pkgs, ... }: | |
{ | |
imports = | |
[ # Include the results of the hardware scan. | |
./hardware-configuration.nix |