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
    
  
  
    
  | #include <dlfcn.h> | |
| #include <cstdio> | |
| #include <iostream> | |
| #include <string> | |
| int main(int argc, char* argv[]) { | |
| if (argc <= 1) { | |
| std::cerr << argv[0] << " <so filepath> [RTLD_NOW|RTLD_LAZY]" << std::endl; | |
| return 1; | 
  
    
      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
    
  
  
    
  | /** | |
| * Advanced Window Snap | |
| * Snaps the Active Window to one of nine different window positions. | |
| * | |
| * @author Andrew Moore <andrew+github@awmoore.com> | |
| * @version 1.0 | |
| */ | |
| /** | |
| * SnapActiveWindow resizes and moves (snaps) the active window to a given position. | 
  
    
      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
    
  
  
    
  | (Get-WmiObject -Namespace root/WMI -Class WmiMonitorBrightnessMethods).WmiSetBrightness(1,5) | 
  
    
      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
    
  
  
    
  | Add-Type -Assembly PresentationCore | |
| $img = [Windows.Clipboard]::GetImage() | |
| if ($img -eq $null) { | |
| Write-Host "You cannnot get image form clipboard!" | |
| Start-Sleep -s 10 | |
| Exit | |
| } | |
| Write-Host ("Clipboard image data: {0}x{1} Pixel." -f $img.PixelWidth, $img.PixelHeight) | |
| $data = new-object Windows.Media.Imaging.FormatConvertedBitmap($img, [Windows.Media.PixelFormats]::Rgb24, $null, 0) | 
  
    
      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
    
  
  
    
  | *://www.tech-teacher.jp/* | |
| *://programming-study.com/* | |
| *://techacademy.jp/* | |
| *://techplay.jp/* | |
| *://golang.jp/* | |
| *://*.coder.work/* | |
| *://*.ojit.com/* | |
| *://*.stackovernet.com/* | |
| *://*.stackovernet.xyz/* | |
| *://ask.xiaolee.net/* | 
  
    
      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
    
  
  
    
  | #IfWinActive,ahk_exe Typora.exe | |
| ^a:: | |
| { | |
| send, {Home} | |
| Return | |
| } | |
| ^e:: | |
| { | |
| send, {End} | |
| Return | 
  
    
      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
    
  
  
    
  | #Persistent | |
| OnClipboardChange("ClipChanged") | |
| Return | |
| ; hook ^+v and send ^+v don't work well... | |
| ;^+u:: ; Ctrl + Shift + u | |
| ;{ | |
| ; ; update clipboard as plaintext (clear html format) | |
| ; content = %Clipboard% | |
| ; Clipboard = %content% | 
  
    
      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
    
  
  
    
  | #Include WinClipAPI.ahk | |
| #Include WinClip.ahk | |
| ^+y:: ; Ctrl + Shift + y | |
| { | |
| wc := new WinClip | |
| html = %Clipboard% | |
| ; for test | |
| ; html = <pre><span style="color:red;">hoge</span></pre> | |
| WinClip.Clear() | 
  
    
      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
    
  
  
    
  | global g_tmux_prefix_access_time := 0 | |
| GetCurrentTimeAsMilliSeconds() { | |
| millis := (a_hour * 3600 + a_min * 60 + a_sec) * 1000 + a_msec | |
| Return millis | |
| } | |
| IsTmuxAccess() { | |
| now := GetCurrentTimeAsMilliSeconds() | |
| sub := now - g_tmux_prefix_access_time | 
  
    
      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
    
  
  
    
  | #include <chrono> | |
| #include <fstream> | |
| #include <iostream> | |
| #include <thread> | |
| int main(int argc, char* argv[]) { | |
| if (argc < 2) { | |
| std::cerr << "Usage: " << argv[0] << " " | |
| << "cpu_ratio" << std::endl; | |
| return 1; | 
OlderNewer