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
Set-Content -Path "$env:TEMP\temp.wsb" -Value (Get-Content "$PSScriptRoot\template.wsb" | % { $_ -replace "%CURRENT%", $PSScriptRoot }) | |
Start-Process $env:TEMP\temp.wsb -Wait | |
Remove-Item "$env:TEMP\temp.wsb" |
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
while($True){ if((dir ./*.*).Length -ne 0){C:\Windows\Media\Alarm01.wav; break} sleep 1 } |
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
// 今後使う機会あるかないか分からないけど。 | |
// ブリゲード - Code for JapanCode for Japan https://www.code4japan.org/brigade で、開発者コンソールを開き以下をコピペ | |
let t = ""; Array.from(document.querySelectorAll(".list--brigade li")).forEach((e) => { t = `${t}${e.innerText} @ ${e.querySelector("a") ? e.querySelector("a").href : "URL None"}\n` }); console.log(t); |
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
// SharePointリストを表示し、一つの列でグループ化した状態で、下の行を開発者コンソールに入れて実行 | |
Array.from(document.querySelectorAll(".ms-GroupedList-group")).forEach(e => console.log(e.querySelector(".ms-GroupHeader-title").textContent)); |
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
# ローカル環境ならこれでOK。PaizaIOだと動かない。 | |
# コピペでコンソールに貼り付ければ動く | |
import datetime | |
import calendar | |
import locale | |
import jpholiday | |
locale.setlocale(locale.LC_ALL, 'ja_JP.UTF-8') | |
def daterange(_start, _end): |
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
# コピペで使うとよさげ | |
dir | rename-item -newname { $_.name -replace '\A\d\d\s-\s','' } |
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-Item "*.egg-info" -Recurse | |
Remove-Item "dist" -Recurse | |
Remove-Item "build" -Recurse | |
python setup.py sdist | |
python setup.py bdist_wheel | |
$title = "PyPI upload?" | |
$message = "The package was created in the `dist` folder. Can I continue uploading to PyPI?" | |
$tChoiceDescription = "System.Management.Automation.Host.ChoiceDescription" | |
$options = @( | |
New-Object $tChoiceDescription ("Yes(&Y)", "Upload the library to PyPI.") |
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
// See the right for details. https://qiita.com/TakamiChie/items/e7c8e7ed5d37949298cd | |
// ==ClosureCompiler== | |
// @compilation_level ADVANCED_OPTIMIZATIONS | |
// @output_file_name default.js | |
// ==/ClosureCompiler== | |
// ADD YOUR CODE HERE | |
(function(){ | |
a = ""; | |
f = document.querySelector(".ms-DetailsRow-cellCheck div:first-child[aria-checked=true]") == null; |
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
; Clipboard-History用のRe:Viewのキーワードリストです。 | |
; @include=reviewkwds.txtなどとしてお使いください。 | |
+ブロック命令(&B) | |
リスト(&L) | //listnum[id][caption][lang]{`r`n`r`n//}`r`n | |
埋め込みリスト(&E) | //emlistnum[id][caption][lang]{`r`n`r`n//}`r`n | |
行番号指定(&F) | //firstlinenum[num]`r`n | |
コマンド(&C) | //cmd{`r`n`r`n//}`r`n | |
イメージ(&G) | //image[id][caption]{`r`n`r`n//}`r`n | |
番号無し図(&P) | //indepimage[id][caption]`r`n |
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
""" | |
Sentenceフォルダ配下のファイルをコピーして貼り付ける | |
uwstyle, pyperclipモジュールのインストールが必要 | |
`pip install uwstyle, pyperclip` | |
# Clipboard-Historyで使う場合の例 | |
センテンスフォルダ(&S) || Run | C:\Users\TakamiChie\AppData\Local\Packages\6432853C62D86.ClipboardHistory_mmq3pnrvshaxt\LocalCache\Roaming\ClipboardHistory\choosesentence.py | I O | |
""" | |
from uwstyle.dialogs import select | |
from pathlib import Path | |
import pyperclip |