Skip to content

Instantly share code, notes, and snippets.

View ogaty's full-sized avatar

Yuji Ogata ogaty

View GitHub Profile
<?php
$args = array(
// ↓ 特定の「著者」に関連付けられた投稿を表示する場合
'author' => '1,2,3', // 著者IDを指定
'author_name' => 'solecolor', // user_nicknameを指定(名前ではありません)
'author__in' => array( 2 , 6 ), // 著者IDを配列で指定(著者IDを含む記事を絞り込む)
'author__not_in' => array( 2 , 6 ), // 著者IDを配列で指定(著者IDを含まない記事を絞り込む)
// ↓ 特定の「カテゴリー」に関連付けられた投稿を表示する場合
'cat' => 5, // カテゴリーIDを指定
@ogaty
ogaty / show-all-256-colors.py
Created August 6, 2018 10:37 — forked from mgedmin/show-all-256-colors.py
Script to show all 256 colors supported by xterms
#!/usr/bin/python
"""Print a swatch using all 256 colors of 256-color-capable terminals."""
__author__ = "Marius Gedminas <marius@gedmin.as>"
__url__ = "https://gist.github.com/mgedmin/2762225"
__version__ = '2.0'
def hrun(start, width, padding=0):