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
| [{"action":"javascript","blacklist":"whitelist","code":"iframe = document.querySelector('#YouTube > iframe')\nid = iframe.src.match(/([0-9a-zA-Z]+)?$/)[0]\nhistory.go(id?-1:-2)","customName":"Go back","exported":true,"key":"a","open":false,"sites":"https://dova-s.jp/bgm/play*","sitesArray":["https://dova-s.jp/bgm/play*"]},{"action":"javascript","blacklist":"whitelist","code":"console.log('-- Play youtube movie')\niframe = document.querySelector('#YouTube > iframe')\nid = iframe.src.match(/([0-9a-zA-Z]+)?$/)[0]\nif (id) {\n\tiframe.src += `?autoplay=1&playlist=${id}&muted=1&`\n playedBgms = JSON.parse(localStorage.getItem('playedBgms')) || {}\n \ttitle = document.querySelector('#titleYouTube > h2').firstChild.textContent.trim()\n playedBgms[location.pathname] = title\n localStorage.setItem('playedBgms', JSON.stringify(playedBgms))\n console.log(playedBgms)\n} else {\n \thistory.go(-2)\n}","customName":"Play bgm","exported":true,"key":"space","open":false,"sites":"https://dova-s.jp/bgm/play*","sit |
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
| import ast | |
| source = """ | |
| name = "Inu" | |
| age = 10 | |
| print("Hello, {}({})!".format(name, age)) | |
| """ | |
| tree = ast.parse(source) |
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
| /** | |
| * @file sakura_selection_sample.js | |
| * | |
| * 注:Shift_JISで保存してください (サクラエディタマクロの制約事項) | |
| */ | |
| /** | |
| * 選択範囲(レイアウト座標) | |
| * | |
| * @param {number} lineFrom 選択開始行(レイアウト座標) |
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
| /* | |
| * $ go run flag_sample.go -i 100 -s "strflag" 1 2 3 | |
| * os.Args: [/.../os_args_sample -i 100 -s strflag 1 2 3] | |
| * flag.Args: [1 2 3] | |
| * b: false | |
| * i: 100 | |
| * s: strflag | |
| */ | |
| package main |
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
| package main | |
| import ( | |
| "flag" | |
| "fmt" | |
| ) | |
| func main() { | |
| var ( | |
| boolFlag bool |
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
| package main | |
| import ( | |
| "fmt" | |
| "os" | |
| "io" | |
| "encoding/csv" | |
| ) | |
| func main() { |
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
| package main | |
| import ( | |
| "fmt" | |
| "log" | |
| "os/exec" | |
| ) | |
| func main() { | |
| out, err := exec.Command("ls", "-l").Output() |
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
| package main | |
| import ( | |
| "fmt" | |
| "regexp" | |
| ) | |
| func main() { | |
| fmt.Println("Hello, playground") | |
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
| /** | |
| * @file 選択した英文を日本語に翻訳 | |
| * | |
| * 注:Shift_JISで保存してください (サクラエディタマクロの制約事項) | |
| */ | |
| var text = Editor.GetSelectedString(0) | |
| .replace(/\r\n/g, '\n') | |
| .replace(/\t/g, '') | |
| .replace(/\. /g, '.\n'); |
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
| #!/bin/bash | |
| # カレントディレクトリのすべてのファイルのTab文字をスペースに変換するワンライナー | |
| find -maxdepth 1 -type f | grep -v "\.bak$" | while read f; do expand -t 4 "$f" > "$f.bak"; mv "$f.bak" "$f"; done |