Skip to content

Instantly share code, notes, and snippets.

View odelrio's full-sized avatar

Oriol del Rio odelrio

View GitHub Profile
@odelrio
odelrio / userChrome.css
Created December 16, 2022 09:25
Firefox roomy bookmarks (excluding folders)
.bookmark-item > .toolbarbutton-text {
margin-top: -1px !important;
}
.bookmark-item:not(:hover):not([open="true"]):not([container="true"]) > .toolbarbutton-text {
display: none !important;
}
#PlacesToolbarItems > .bookmark-item:not(:hover):not([open="true"]):not([container="true"]) > .toolbarbutton-icon[label]:not([label=""]) {
margin-inline-end: 0px !important;
@odelrio
odelrio / gist:250ff3ab186ade1c7d3119ec847804be
Created December 21, 2020 00:28
Install PHP 8.0 with phpbrew (macOS Big Sur)
brew install libzip
brew install readline
brew install oniguruma
brew install bzip2
brew install openssl@1.1
brew install pkg-config
phpbrew --debug install 8.0 +default +pdo +mysql +sqlite +bz2 +zlib

Keybase proof

I hereby claim:

  • I am odelrio on github.
  • I am odelrio (https://keybase.io/odelrio) on keybase.
  • I have a public key ASCqfeQEk_6ILVDaBmPYFFBQiDlsW9c16lij9Psv0c4coAo

To claim this, I am signing this object:

@odelrio
odelrio / gist:8419229e95abf41937a90122a9247727
Created September 29, 2018 23:07
macOS - Increase key repeat (cursor) speed
defaults write -g ApplePressAndHoldEnabled -bool false
defaults write -g InitialKeyRepeat -int 25
defaults write -g KeyRepeat -int 1
@odelrio
odelrio / stripped_mixin.less
Created January 4, 2016 09:54
{LESS} Stripped background generator
.stripped(@direction, @color1, @color2, @size) {
background-image: -webkit-repeating-linear-gradient(@direction, @color1, @color1 25%, @color2 25%, @color2 50%, @color1 50%);
background-image: -moz-repeating-linear-gradient(@direction, @color1, @color1 25%, @color2 25%, @color2 50%, @color1 50%);
background-image: -ms-repeating-linear-gradient(@direction, @color1, @color1 25%, @color2 25%, @color2 50%, @color1 50%);
background-image: -o-repeating-linear-gradient(@direction, @color1, @color1 25%, @color2 25%, @color2 50%, @color1 50%);
background-image: repeating-linear-gradient(@direction, @color1, @color1 25%, @color2 25%, @color2 50%, @color1 50%);
-webkit-background-size: @size * 2 @size * 2;
-moz-background-size: @size * 2 @size * 2;
-o-background-size: @size * 2 @size * 2;
@odelrio
odelrio / br2nl.tpl
Last active November 12, 2015 10:40
Smarty: br2nl modifier
There's no br2nl modifier in Smarty, but you can convert break tags to new line characters by using:
regex_replace:"/<br.?\/?>/":"\n"
E.g.:
<textarea value="{$myText|regex_replace:"/<br.?\/?>/":"\n"}"></textarea>