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
<!DOCTYPE html> | |
<html lang="zh-TW"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>使用 Notepad++ 作為 GitHub 預設的文字編輯器</title> | |
</head> | |
<body> | |
<blockquote>參考來源:<a href="http://www.buildmeimfamous.net/2013/12/use-notepadplusplus-with-git-as-default-editor</a></blockquote> | |
<p><code>GitHub</code> 雖然提供界面讓使用者可以直接輸入內容,但因為 git 的開發目的主要是為了撰寫程式,所以沒有考慮中文顯示的問題。如果要在文章中鍵入中文,建議採用外部編輯器,在這裡推廌使用 Notepad++。</p> | |
<h2>如何將 Notepad++ 設定成 GitHub 的預設編輯器</h2> |
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
var 專長代碼 = { | |
"01": "家電修理", | |
"02": "機械", | |
"03": "汽車修護", | |
"04": "工藝", | |
"05": "刻印", | |
"06": "印刷", | |
"07": "語文", | |
"08": "文書處理", | |
"09": "編輯", |
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
var patt = /^\(0\d{2}\)\d{6}$|^\(0\d{1}\)\d{7,8}$|(^0\d{1})-\d{7,8}$|(^0\d{2})-\d{6}$/ | |
var phones = ['089-335482', '(089)335482', '02-23442798', '(02)23442798']; // correct phone numbers format | |
var length_errors = ['(089)35482', '(089)3354826', '(0889)335482', '(02)335482', '02-335482', '02-234427988']; // improper digits combination | |
var illegal_chars = ['(089)33548-', '(089-335482', '089=335482']; // contains illegal characters or missing essential characters | |
// Function to test pattern match | |
function validate_phone_number( phone ) { | |
var patt = /^\(0\d{2}\)\d{6}$|^\(0\d{1}\)\d{7,8}$|(^0\d{1})-\d{7,8}$|(^0\d{2})-\d{6}$/; | |
return phone.map( function(i) { | |
return patt.test( i ); |
NewerOlder