為了能讓大家能夠順利的建立起 Angular 5 開發環境,以下是需要安裝的相關軟體與安裝步驟與說明。
- Windows 7 以上版本 (更新到最新 Service Pack 版本)
- Mac OS X 10.6 以上版本
| [core] | |
| quotepath = false # 中文檔名如實顯示而不轉碼 | |
| autocrlf = false # commit 及 checkout 時不根據作業系統轉換檔案的換行字元 (避免不小心改動原 repo 的換行字元) | |
| safecrlf = false # 檢查文字類檔案是否混合了 CRLF 及 LF 換行字元 (搭配 autocrlf,這裡一起關閉) | |
| ignorecase = false # 檔名大小寫不同時視為相異 (更動大小寫才能 commit) | |
| whitespace = cr-at-eol # diff 時行尾 CRLF 不顯示 ^M | |
| fileMode = false # 忽略檔案的 x 屬性 (for Windows) | |
| symlinks = false # 忽略符號連結 (for Windows) | |
| editor = /usr/bin/vim # 預設的文字編輯器 (for Linux) | |
| [alias] |
| public static class LINQPadExtensions | |
| { | |
| private static readonly Dictionary<Type, string> TypeAliases = new Dictionary<Type, string> { | |
| { typeof(int), "int" }, | |
| { typeof(short), "short" }, | |
| { typeof(byte), "byte" }, | |
| { typeof(byte[]), "byte[]" }, | |
| { typeof(long), "long" }, | |
| { typeof(double), "double" }, | |
| { typeof(decimal), "decimal" }, |
A simple Ghostscript command to merge two PDFs in a single file is shown below:
gs -dNOPAUSE -sDEVICE=pdfwrite -sOUTPUTFILE=combine.pdf -dBATCH 1.pdf 2.pdfInstall Ghostscript:
Type the command sudo apt-get install ghostscript to download and install the ghostscript package and all of the packages it depends on.
| git branch -m old_branch new_branch # Rename branch locally | |
| git push origin :old_branch # Delete the old branch | |
| git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote |
| -- ------------------------------- | |
| -- Watcher for changes of init.lua | |
| -- ------------------------------- | |
| function reloadConfig(files) | |
| doReload = false | |
| for _,file in pairs(files) do | |
| if file:sub(-4) == ".lua" then | |
| doReload = true | |
| end | |
| end |
| git config --global core.preloadindex true | |
| git config --global core.fscache true |
| @echo off | |
| SET codePath=C:\Program Files (x86)\Microsoft VS Code\code.exe | |
| rem add it for all file types | |
| @reg add "HKEY_CLASSES_ROOT\*\shell\Open with VS Code" /t REG_SZ /v "" /d "Open with VS Code" /f | |
| @reg add "HKEY_CLASSES_ROOT\*\shell\Open with VS Code" /t REG_EXPAND_SZ /v "Icon" /d "%codePath%,0" /f | |
| @reg add "HKEY_CLASSES_ROOT\*\shell\Open with VS Code\command" /t REG_SZ /v "" /d "%codePath% \"%%1\"" /f | |
| rem add it for folders | |
| @reg add "HKEY_CLASSES_ROOT\Folder\shell\Open with VS Code" /t REG_SZ /v "" /d "Open with VS Code" /f |
| @echo off | |
| SET st3Path=C:\Program Files\Sublime Text 3\sublime_text.exe | |
| rem add it for all file types | |
| @reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3" /t REG_SZ /v "" /d "Open with Sublime Text 3" /f | |
| @reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3" /t REG_EXPAND_SZ /v "Icon" /d "%st3Path%,0" /f | |
| @reg add "HKEY_CLASSES_ROOT\*\shell\Open with Sublime Text 3\command" /t REG_SZ /v "" /d "%st3Path% \"%%1\"" /f | |
| rem add it for folders | |
| @reg add "HKEY_CLASSES_ROOT\Folder\shell\Open with Sublime Text 3" /t REG_SZ /v "" /d "Open with Sublime Text 3" /f |
| public static string GetKeyDownString(KeyEventArgs args) | |
| { | |
| var value = ""; | |
| if ((Keyboard.Modifiers & ModifierKeys.Control) > 0) | |
| { | |
| value += "Ctrl+"; | |
| } | |
| if ((Keyboard.Modifiers & ModifierKeys.Alt) > 0) |