This file contains 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/env python3 | |
'''Findmedia - generate a (play)list of specified filetypes''' | |
import os | |
__revision__ = '8' | |
vidia = ('3gp', 'AVI', 'VOB', 'WMV', 'wmv', 'avi', 'flv', 'mka', 'mkv', | |
'mov', 'mp4', 'mpeg', 'mpg', 'vob', 'ogm') | |
newformats = ('webm') |
This file contains 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
@echo off | |
if exist "*.jpg" (md ".\jpg\") && (move *.jpg ".\jpg\") && (move *.jpeg ".\jpg\") ELSE (echo no jpg) | |
if exist "*.tga" (md ".\tga\") && (move *.tga ".\tga\") ELSE (echo no tga) | |
if exist "*.bmp" (md ".\bmp\") && (move *.bmp ".\bmp\") ELSE (echo no bmp) | |
if exist "*.gif" (md ".\gif\") && (move *.gif ".\gif\") ELSE (echo no gif) | |
if exist "*.psd" (md ".\psd\") && (move *.psd ".\psd\") ELSE (echo no psd) | |
if exist "*.png" (md ".\png\") && (move *.png ".\png\") ELSE (echo no png) |
This file contains 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
def a(): | |
print("a") | |
def b(): | |
print("b") | |
def default(): | |
print("default") |
This file contains 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
/* header__search {{{3 */ | |
/* use postcss-next */ | |
&__search { | |
text-align: right; | |
cursor: pointer; | |
position: relative; | |
@nest & .screen-reader-text { | |
position: absolute; | |
left: -9999px; | |
top: -99999px; |
This file contains 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
<div class="header__contacts col-9 col-m-12"> | |
<div class="col-8 col-m-12"> | |
<?php $_phone = get_field('site_phone', 'options'); | |
$_tel = preg_replace("/[^0-9]/", "", $_phone); ?> | |
<p><a href="tel:+<?php echo $_tel;?>" class="phone"><?php echo $_phone; ?></a></p> | |
<p><?php the_field('site_adress', 'options'); ?></p> | |
</div> | |
<div class="col-4 col-m-12 header__btns"><a class="btn js-mopen" href="#modal">Заказать консультацию</a></div> | |
</div> |
This file contains 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( function_exists('acf_add_options_page') ) { | |
acf_add_options_page(array( | |
'menu_title' => 'Настройки контента', | |
'menu_slug' => 'theme-general-settings', | |
'capability' => 'edit_posts', | |
//'icon_url' => '/wp-content/themes/tt_landing/favicon.png', | |
'post_id' => 'options', | |
'position' => 2, | |
'redirect' => true | |
)); |
This file contains 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
<?php if (1): ?> | |
<h1 class="title title-debug" style="position: fixed; bottom:20px; right: 0; margin: 16px 0; padding: 10px; border-radius: 8px 0 0 8px; font-size: 16px; background-color: #d4e0c1; opacity: .42; z-index: 9999; user-select: none; text-shadow: 1px 1px 0px green, 1px 2px 3px rgba(0,255,0,.3), 3px 3px 3px hsla(173, 67%,47%,.75), -1px -1px 0px red, -3px -3px 3px rgba(255,0,0,.3);"> | |
<!-- debug --> | |
<?php global $template; echo basename($template); ?> | |
</h1> | |
<?php endif; ?> |
This file contains 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
remove_filter( 'the_content', 'wpautop' ); | |
remove_filter( 'the_content', 'wptexturize' ); | |
remove_filter( 'the_excerpt', 'wpautop' ); | |
remove_filter( 'comment_text', 'wpautop' ); |
This file contains 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
// show tax id's in admin panel: | |
// https://wordpress.stackexchange.com/a/77536 | |
foreach ( get_taxonomies() as $taxonomy ) { | |
add_action( "manage_edit-${taxonomy}_columns", 't5_add_col' ); | |
add_filter( "manage_edit-${taxonomy}_sortable_columns", 't5_add_col' ); | |
add_filter( "manage_${taxonomy}_custom_column", 't5_show_id', 10, 3 ); | |
} | |
add_action( 'admin_print_styles-edit-tags.php', 't5_tax_id_style' ); | |
function t5_add_col( $columns ) |
This file contains 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
" cvim config v.0.0.1 | |
map gr gT | |
map gb :buffer<Space> | |
"================================================== | |
" russian langmap for hotkeys to work in both kb layouts | |
" credit: https://gist.github.com/rynffoll/7bb30a47b3b8d39687f588ecc2be5425 | |
" also: https://gist.github.com/MaxLevs/f519d361d3946d6d877085f909e13043 | |
let langmap = "Ё|АFБ<ВDГUДLЕTЖ:ЗPИBЙQКRЛKМVНYОJПGРHСCТNУEФAХ{ЦWЧXШIЩOЪ}ЫSЬMЭ\"Ю>ЯZаfб\\,вdгuдlеtж\\;зpиbйqкrлkмvнyоjпgрhсcтnуeфaх[цwчxшiщoъ]ыsьmэ'ю.яzё\\№#" | |
"================================================== | |
let blacklists = ["http://www.typing.com/*","http://www.heuxasoftware.com/*","http://www.keybr.com/*","http://www.reddit.com/*","https://sirxemic.github.io/*","http://vim-adventures.com/*","https://mail.google.com/*","https://timeinvariant.github.io/*","http://www.platinumgames.co.jp/*","http://codecombat.com/*","http://johanw123.nu/*","http://hughsk.io/*","https://np.reddit.com/*","chrome-extension://hgimloonaobbeeagepickockgdcghfnn/*","https://blastar-1984.appspot.com/*","http://redditp.com/*", |