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
function! LightlineFiletype() | |
if &filetype ==? 'ruby' | |
return '' | |
elseif &filetype ==? 'javascript' | |
return '' | |
endif | |
return &filetype | |
endfunction |
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
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() | |
Plug 'thinca/vim-localrc' " Local .vimrc files | |
Plug 'vim-ruby/vim-ruby' |
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
#!/usr/bin/bash | |
function _open() { | |
spotify_uri=$1 | |
is_spotify_running=$(pgrep spotify) | |
if [[ $is_spotify_running ]]; then | |
dbus-send --type=method_call --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.OpenUri string:$spotify_uri | |
else | |
spotify --uri=$spotify_uri |
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
module.exports = async function(data) { | |
if(data.type == 'remote-play') { | |
// The play button was pressed, we can forward this command to the player using | |
TrackPlayer.play(); | |
} else if(data.type == 'remote-pause') { | |
TrackPlayer.pause(); | |
} else if(data.type == 'remote-stop') { | |
TrackPlayer.stop(); | |
} | |
}; |
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
/** | |
* Sample React Native App | |
* https://github.com/facebook/react-native | |
* | |
* @format | |
* @flow | |
*/ | |
import React, {PureComponent} from 'react'; | |
import { |
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
resource = ARGV[0] | |
directory_pattern = "*#{resource}*/*_spec.rb" | |
single_spec_pattern = "*/*#{resource}*_spec.rb" | |
resource_pattern = "**/{#{directory_pattern},#{single_spec_pattern}}" | |
Dir.chdir("spec") | |
spec_files = Dir.glob(resource_pattern).sort.uniq.join(" ") | |
system("rspec #{spec_files}") |
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
unbindall | |
bind "CapsLock" "use weapon_smokegrenade" | |
bind "0" "slot10" | |
bind "1" "slot1" | |
bind "2" "slot2" | |
bind "3" "slot3" | |
bind "4" "slot4" | |
bind "5" "slot5" | |
bind "6" "slot6" | |
bind "7" "slot7" |
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
if [endereco.rua, endereco.cidade, endereco.cep].any?(&:blank?) | |
#do something | |
end |
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
15:06:46 search.1 | starts elasticsearch | |
15:06:46 search.1 | | |
15:06:46 search.1 | Option Description | |
15:06:46 search.1 | ------ ----------- | |
15:06:46 search.1 | -E <KeyValuePair> Configure a setting | |
15:06:46 search.1 | -V, --version Prints elasticsearch version information and exits | |
15:06:46 search.1 | -d, --daemonize Starts Elasticsearch in the background | |
15:06:46 search.1 | -h, --help show help | |
15:06:46 search.1 | -p, --pidfile <Path> Creates a pid file in the specified path on start | |
15:06:46 search.1 | -q, --quiet Turns off standard ouput/error streams logging in console |
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
15:06:46 search.1 | starts elasticsearch | |
15:06:46 search.1 | | |
15:06:46 search.1 | Option Description | |
15:06:46 search.1 | ------ ----------- | |
15:06:46 search.1 | -E <KeyValuePair> Configure a setting | |
15:06:46 search.1 | -V, --version Prints elasticsearch version information and exits | |
15:06:46 search.1 | -d, --daemonize Starts Elasticsearch in the background | |
15:06:46 search.1 | -h, --help show help | |
15:06:46 search.1 | -p, --pidfile <Path> Creates a pid file in the specified path on start | |
15:06:46 search.1 | -q, --quiet Turns off standard ouput/error streams logging in console |
NewerOlder