跳到主要內容

發表文章

目前顯示的是 2017的文章

[iOS][轉]ARKit从入门到精通

ARKit 从入门到精通( 1 ) -ARKit 初体验 http://blog.csdn.net/u013263917/article/details/72903174   ARKit 从入门到精通( 2 ) -ARKit 工作原理及流程介绍 http://blog.csdn.net/u013263917/article/details/73038519   ARKit 从入门到精通( 3 ) -ARKit 自定义实现 http://blog.csdn.net/u013263917/article/details/73038566   ARKit 从入门到精通( 4 ) -ARKit 全框架 API 大全 http://blog.csdn.net/u013263917/article/details/73156679   ARKit 从入门到精通( 5 ) -ARScnView 介绍 http://blog.csdn.net/u013263917/article/details/73156918   ARKit 从入门到精通( 6 ) -ARSession 介绍 http://blog.csdn.net/u013263917/article/details/73157082   ARKit 从入门到精通( 7 ) -ARCamera 介绍 http://blog.csdn.net/hdfqq188816190/article/details/73360281   ARKit 从入门到精通( 8 ) -ARKit 捕捉平地 http://blog.csdn.net/u013263917/article/details/73161048   ARKit 从入门到精通( 9 ) -ARKit 让飞机跟着镜头飞起来 http://blog.csdn.net/hdfqq188816190/article/details/73360301   ARKit 从入门到精通( 10 ) -ARKit 让飞机绕着你飞起来 http://blog.csdn.net/hdfqq188816190/article/details/73360319   ARKit 从入门到精通( 11 ) -ARKit 开发常见问题及解决方案 h

[iOS] 取得外部IP

  - ( NSString *)externalIPAddress {     // see https://stackoverflow.com/questions/27708887/objective-c-how-to-get-the-public-ip-address-of-the-device/27709110#27709110     // http://myipdoc.com/ip.php     NSString *publicIP = [ NSStringstringWithContentsOfURL :[ NSURLURLWithString : @"https://icanhazip.com/" ] encoding : NSUTF8StringEncodingerror : nil ];     publicIP = [publicIP stringByTrimmingCharactersInSet :[ NSCharacterSetnewlineCharacterSet ]];     return publicIP;   }

[iOS] Status Br Style

From  https://stackoverflow.com/questions/45372550/preferredstatusbarstyle-is-not-working If you want to set status bar style, application level then set  UIViewControllerBasedStatusBarAppearance  to  NO  in your  .plist  file. And in your  appdelegate >  didFinishLaunchingWithOptions  add following ine. [ UIApplication sharedApplication ] setStatusBarStyle : UIStatusBarStyleLightContent animated : YES ]; if you wan to set status bar style, at view controller level then follow these steps: Set the  UIViewControllerBasedStatusBarAppearance  to  YES  in the  .plist  file, if you need to set status bar style at UIViewController level only. In the viewDidLoad add function -  setNeedsStatusBarAppearanceUpdate override preferredStatusBarStyle in your view controller. - - ( void ) viewDidLoad { [ super viewDidLoad ]; [ self setNeedsStatusBarAppearanceUpdate ]; } - ( UIStatusBarStyle ) preferredStatusBarStyle { return UIStatusBarStyleLightContent ; }

[ffmpeg] 影片轉檔

VideoConvert.sh FULL_FILE_NAME=$1 EXTENSION_NAME="${FULL_FILE_NAME##*.}" FILE_NAME="${FULL_FILE_NAME%.*}" NEW_FILE_FULL_NAME="${FILE_NAME}.mp4" #ffmpeg -y -i $FULL_FILE_NAME \ #-c:v libx264 \ #-vf scale=640:-1 \ #-color_primaries 1 -color_trc 1 -colorspace 1 \ #-r 29.92 \ #-b:v 340K \ #-profile:v baseline \ #-g 90 \ #-keyint_min 0 \ #-bf 0 \ #-sc_threshold 40 \ #-coder 0 \ #-c:a aac \ #-ar 44100 \ #-b:a 96k \ #-ac 2 \ #-level 3.1 \ #-movflags +faststart \ #-brand isom \ #../output/$NEW_FILE_FULL_NAME #ffmpeg -y -i $FULL_FILE_NAME \ #-c:v libx264 \ #-s 480x320 \ #-color_primaries 1 -color_trc 1 -colorspace 1 \ #-r 23.796 \ #-b:v 1440K \ #-profile:v main \ #-g 90 \ #-keyint_min 0 \ #-bf 0 \ #-sc_threshold 40 \ #-coder 0 \ #-c:a aac \ #-ar 44100 \ #-b:a 128k \ #-ac 2 \ #-level 3.1 \ #-movflags faststart \ #../output/$NEW_FILE_FULL_NAME ffmpeg -y -i $FULL_FILE_NAME \ -c:v libx264 \ -vf scale=1280:-1 \ -crf:v 18 \ -color_primaries 1 -color_trc 1 -colorspac

[AWS] update SNS credentials

  官方說明︰ http://docs.aws.amazon.com/zh_cn/sns/latest/dg/mobile-push-apns.html 但要上傳的是這個p12  

[iOS] Singleton pattern in objc, how to keep init private?

From https://stackoverflow.com/questions/7034971/singleton-pattern-in-objc-how-to-keep-init-private Throw an exception in init - (instancetype)init { [self doesNotRecognizeSelector:_cmd]; return nil; } - (instancetype)initPrivate { self = [super init]; if (self) { } return self; } + (instancetype)sharedInstance { static MySingleton *sharedInstance; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ sharedInstance = [[self alloc] initPrivate]; }); return sharedInstance; } Have init return your singleton - (instancetype)init { return [[self class] sharedInstance]; } - (instancetype)initPrivate { self = [super init]; if (self) { } return self; } + (instancetype)sharedInstance { static MySingleton2 *sharedInstance; static dispatch_once_t onceToken; dispatch_once(&onceToken, ^{ sharedInstance = [[self alloc] initPrivate]; }); return sharedInstance; }

[Ukulele] 香格里拉 solo

                       

[Survey] 尷尬症研究

話說我小時候很常拉肚子,所以很怕一些大型場合,像是升期典禮之類的 一肚子痛就得去跟老師報備,很不好意思,所以都會忍到真的不行時才會說,真的很痛苦吶 後來要當兵時更是擔心會不會死在集合場上 誰知道當兵的時候超少拉肚子的,想說是不是老天爺有保佑,但怎麼可能咧 退伍後仔細想想才發現這個名詞「乳醣不耐症」… 幹,原來我有乳醣不耐症,害我每天喝牛奶拉了20幾年的肚子,沒知識真的很可怕啊~     最近又發現這個詞「尷尬症」 我覺得我應該也滿嚴重的,大概有第3期那麼嚴重 可憐我連怎麼造成的怎麼解決都沒有頭緒啊… 明明在工作上完全沒有這種問題的啊…XD   唉,研究先…   網路上的相關文章︰ 美國人為什麼不患「尷尬症」 http://edu.163.com/16/0222/11/BGE5S8R500294IIH.html 面對陌生人,你為什麼會「尷尬症」發作? https://read01.com/3ky0R3.html     2017/07/31 一個尷尬癌患者的自我治療 https://kknews.cc/psychology/x56r99.html 這篇講到一個名詞 - 「長走廊綜合症」… 幹!還真是心有悽悽焉啊 文章節錄︰ - 心理學家們相信,尷尬是一種高標準的自我要求。 - 大部分尷尬是在社交過程中產生的, 是顧及他人感受產生的自我意識情緒 。 - 尷尬本身不需要太過警惕。 唯一值得注意的是,過分的尷尬情緒會轉化成羞愧 。 - 最好的解藥其實是換個角度看問題,比如換成別人的角度,或者乾脆換個外太空的角度。 - 前美國第一夫人,埃莉諾‧羅斯福曾說過一句話: 「當你知道別人壓根不怎麼看你時,你就不會那麼在意別人的目光。」 - 如果能夠清楚認識到我們只是渺小並且也不怎麼特別的個體 ,那麼尷尬往事也就隨風飄散了。 我對長走廊問題採用了以下權宜之計: 1.只要看見了對方,就不要試圖移開視線。否則目光投向哪裡,哪裡就寫著尷尬。 2.距離太遠的時候不要大聲打招呼。因為大聲喊「你好」本身,和接下來的沉默都更令人崩潰。 3.主動接觸對方目光,釋放善意。面帶微笑,或者揮手。不要死盯著對方眼睛,也不能反覆上下打量。減弱直視的方式可以將目光投向鼻子,或者嘴巴的區域。 4.直到只有三米左右的距離,再輕輕的說一句,hello。

小米路由器 mini 刷機

這次會來刷機是因為要給 MOD 使用 但原本的 小米路由器 mini 沒支援 IPTV 不想再買一台路由器(已經有四台了XD,有3台是被淘汰的)   參考文章︰ 1.  ERIC的攝影世界 - 小米路由器mini 免USB打開SSH  ( 備份檔案 ) 2.  ERIC的攝影世界 - 小米路由器mini韌體刷openwrt PandoraBox韌體  ( 備份檔案 ) 3.  寫寫東西 分享心得 - 小米路由器mini 改韌體 可看中華電信MOD iptv功能開啟 刷機 刷rom 直通MOD 老毛子Padavan固件 華碩 RT-AC54U  ( 備份檔案 )   其實找了很多篇文章,大部份都教用官方的那招,但不知道為什麼我就是取不到SSH的密碼 https://d.miwifi.com/rom/ssh  這個一直導不到要的那頁… 所以後來是用了  ERIC的攝影世界 - 小米路由器mini 免USB打開SSH  的第二招  免USB打開SSH 步驟︰ 1. 手動更新韌體到小米路由器mini 穩定版 2.8.14 ( 備用檔案 ) 2. 然後按  ERIC的攝影世界 - 小米路由器mini 免USB打開SSH  的 1.2.3.4.5   2.1 登入  小米路由器mini控制台  後複制網址     http://192.168.31.1/cgi-bin/luci/;stok=521b849e00a11c5b6743aa275ba84ed8 /web/home#router   2.2 將下面的網址紅色部份換成自己的,然後再貼到Browser上     http://192.168.31.1/cgi-bin/luci/;stok=521b849e00a11c5b6743aa275ba84ed8 /api/xqsystem/set_name_password?oldPwd=路由器控制台管理密碼&newPwd=admin     順利的會得到  {"code":0}   2.3 將下面的網址紅色部份換成自己的,然後再貼到Browser上     http://192.168.31.1/cgi-bin/luci/;stok=521b849e00a11c5b6743aa275ba84ed8 /api/x

[Ukulele] 你被寫在我的歌裡 solo

   

[Guitar] 演員 solo

   

[Ukulele] 演員 solo

[APP] 來看一下別人的更新描述都寫啥

       

北京薪水比較

  http://www.jobui.com/salary/%E5%8C%97%E4%BA%AC-java%E5%B7%A5%E7%A8%8B%E5%B8%88/ http://www.jobui.com/salary/%E5%8C%97%E4%BA%AC-android%E5%BC%80%E5%8F%91/ http://www.jobui.com/salary/%E5%8C%97%E4%BA%AC-ios%E5%BC%80%E5%8F%91%E5%B7%A5%E7%A8%8B%E5%B8%88/ http://www.jobui.com/salary/%E5%8C%97%E4%BA%AC-python%E5%B7%A5%E7%A8%8B%E5%B8%88/ http://www.jobui.com/salary/%E5%8C%97%E4%BA%AC-node.js/          

[iOS] Objective-c 比較 兩個 日期 NSDate

// 感覺應該是用排序的邏輯,desc:前面的比較大 // true: date1 大於 date2 BOOL result = [date1 compare:date2] == NSOrderedDescending; // true: date1 小於 date2 BOOL result = [date1 compare:date2] == NSOrderedAscending; // true: date1 等於 date2 BOOL result = [date1 compare:date2] == NSOrderedSame; // true: date1 大於等於 date2 BOOL result = [date1 compare:date2] == NSOrderedDescending || [date1 compare:date2] == NSOrderedSame;

[Android] Video Support

  Android Media Support https://developer.android.com/guide/topics/media/media-formats.html ffmpeg https://ffmpeg.org/ffmpeg.html http://lnpcd.blogspot.tw/2012/07/ffmpeg-mp4.html 在Mac OSX上安裝ffmpeg && ffmpeg命令行將h264封裝為mp4 https://depthlove.github.io/2015/09/24/install-ffmpeg-to-MacOSX-and-use-ffmpeg-to-transform-h264-to-mp4/ FFmpeg 中文文件計畫 https://sites.google.com/site/ffmpegdoc/man-page   Test ffmpeg -y -i i.mpg -c:v libx264 -vf scale=1280:720 -c:a aac -b:v 1.5M -b:a 192k -pass 1 o.mp4 ffmpeg -y -i 20170504022437.mp4 -framerate 30 -c:v libx264 -vf scale=1280:720 -c:a aac -strict -2 -b:v 1.5M -b:a 128k ../output/20170504022437.m4v ffmpeg -y -r 30 -i 20170504022437.mp4 -c:v libx264 -vf scale=1280:720 -c:a libvo_aacenc -b:v 1.5M -b:a 128k ../output/20170504022437.m4v FULL_FILE_NAME=$1 EXTENSION_NAME="${FULL_FILE_NAME##*.}" FILE_NAME="${FULL_FILE_NAME%.*}" NEW_FILE_FULL_NAME="$FILE_NAME.m4v" ffmpeg -y -i $FULL_FILE_NAME \ -c:v libx264

[NodeJS] Remote log - console.re

官網: http://console.re/   使用方式︰ 1.先產生一組隨機的Channel Name 2.這個Channel Name要複制起來,程式裡面會用到 3.點GO就會進到log的console For Node.js 安裝︰ npm install console-remote-client 使用︰ var consolere = require('console-remote-client').connect('console.re','80','b544-248d-ac9a'); console.re.log('remote log test');   以上      

[Redis] Redis Server

官網: https://redis.io/ Redis是一個開源的NoSQL資料庫,以一個key對應一個value的方式並配合記憶體(RAM)來儲存資料,效能要比關聯式資料庫還要好很多,可以在許多程式語言上使用。Redis的value除了字串(string)型態之外,另外還有幾種比較特殊的結構,包括set、zset、list和hash,並提供了多種方式來操作這些欄位。   For Windows: 似乎不支援Windows...於是… [料理佳餚] 在 Windows 上安裝 Redis: https://dotblogs.com.tw/supershowwei/2015/12/23/124549 https://github.com/MSOpenTech/redis/releases   For Mac: 自己compile  http://www.jianshu.com/p/6b5eca8d908b 用homebrew  http://www.jianshu.com/p/af33284aa57a   For ubuntu: Ubuntu如何架設Redis Server並且與PHP一同使用? https://magiclen.org/ubuntu-redis-php/   等有空再來玩玩~ 上次沒辦法完成的connect-redis總是遺憾吶 Using Redis to handle Session in Node.js https://codeforgeek.com/2015/07/using-redis-to-handle-session-in-node-js/ http://wiki.jikexueyuan.com/project/node-lessons/cookie-session.html   查詢Redis的方式 For MAC 連線到Redis Server: telnet [Redis Server IP] [Redis Server Port] 列出所有的Key值: keys * 取得該key的value值:[key]表示keys *取得的key值 get [key] 離線Redis:control+] 離線Telnet:quit 參考︰ https://www.tipga.c

[TV] Sony 4K 55' 規格

主要是比較7000D 及 8500D   直下式 側光式 http://barnvege.pixnet.net/blog/post/69351765 項目 優 缺 Direct-lit (Back-lit) 直下式 區域調光佳 電視厚 均勻度稍佳 全陣列耗電 明暗細節佳 貴 對比度高 Blooming   mura or clouding effect Edge-lit 側光式 電視薄 區域調光差 便宜 漏光明顯   明暗細節差   mura or clouding effect   Sony 官方比較︰ https://www.sony.com.tw/zh/electronics/tv/t/televisions?view=compare&type=4k_hdr     4K 超極真影像處理器 X1™? https://www.mobile01.com/topicdetail.php?f=347&t=5019259 這個貴了10K的東西,感覺是針對類比訊號來加強用的,但畫質差的再怎麼加強也不會有用吧?!  

[PS4 VR] 影片轉檔

怎麼用索尼PSVR看安卓VR 360° 3D視頻 => 將雙眼視頻改成單眼視頻,將格式改成MPEG-4,解析度1920*1080 ,60幀 15000kbps https://kknews.cc/tech/vme9a5l.html ============================================================== Wondershare Filmora:  8.0.0 for Mac 破解版下載 http://www.iphoneba.net/2563.html v8.2.0 http://www.zhinin.com/wondershare_filmora-mac.html ============================================================== for Littlstar http://docs.littlstar.com/plugins/servlet/mobile?contentId=2262863#content/view/2262863 Video Requirements H.264 High@5.1 or lower Max pixel width: 2560 Max frame rate: 60fps (最好是29.97) YUV420/NV12 color space 20Mbps bit rate or lower Audio Requirements Stereo Audio only AAC (Advanced Audio Coding) 320Kbps bit rate or lower Container Requirements File extensions: MP4, MOV No fragmented MP4 No DRM 15 min max duration 以上~ Littlstar不支援平面的3D格式,只支援180或360 而PSVR的媒體播放器不支援3D,只支援360 ============================================================== Make 3D Videos For PSVR Wat

版號的設計

關於版號,其實我都是隨便打的 今天看到這文章才知道原來有人研究過了~   SemVer:  http://semver.org/lang/zh-TW/ Major.Minor.Patch 主版號:當你做了不相容的 API 修改, 次版號:當你做了向下相容的功能性新增, 修訂號:當你做了向下相容的問題修正。   文章中要大家思考 ( Software Versions are Broken ) Breaking.Feature.Fix Breaking : 任何突破性的變化 Feature : 添加任何新功能時 Fix : 安全問題,Bug 修復等等      

[iOS] Universal Links - 待處理

  問題描述︰ 原URL可以在iPhone中直接打開APP 但在iPad中卻會打開Safari再打開AppStore,而沒有直接打開APP   看了該URL的網頁源始碼後發現他使用了 browser-deeplink 但卻只會打開AppStore   HTML裡面寫法類似 這裡 寫的問題 但用Schema似乎會有問題,解決辦法應該是用通用鏈接,如下 iOS9 Universal Links (通用鏈接)   未完待續…

[書法尖]

買墨水 https://tw.bid.yahoo.com/tw/booth/%E9%9F%93%E9%9D%9E%E5%AD%90%E5%B0%8F%E8%88%96-Y9546467215?userID=Y9546467215&u=:Y9546467215&clf=17 網路上推的墨水 Pilot iroshizuku 夕燒   目前鋼筆︰ 英雄 382 目前墨水︰ PILOT ink Black $118/30ml - 很會暈開…   一些文章 http://blog.xuite.net/nonepp/twblog/215710904 https://www.dcard.tw/f/handicrafts/p/158819303   教學︰ 台南市100年度硬筆書法研習實況教學 https://www.youtube.com/watch?v=W5lUxoIE4ok 侯信永 https://www.youtube.com/user/willson0301/videos ohyayeh 葉曄 https://www.youtube.com/channel/UCpmz_IUom-KQGhaa84z40pg 英雄美工鋼筆示範01-行草書 https://www.youtube.com/watch?v=CeL4m5799pc 英雄美工鋼筆示範02-行書 https://www.youtube.com/watch?v=3G3otvvlnrU

[NodeJS] 網頁應用程式設計 使用 Node 和 Express 筆記

express3-handlebars 這個套件已改名為express-handlebars,所以安裝指令為 $ npm install --save express-handlebars 在app.js中設定︰ // 設定handlebar view引擎 var handlebars = require('express-handlebars') .create({defaultLayout:'main'}); app.engine('handlebars', handlebars.engine); app.set('view engine', 'handlebars'); // 並將副檔名指定為hbs var handlebars = require('express-handlebars') .create({extname:'.hbs', defaultLayout:'main'}); app.engine('hbs', handlebars.engine); // 這裡一定要用hbs!!! app.set('view engine', 'hbs'); // 這裡一定要用hbs!!! 官網︰ https://github.com/ericf/express-handlebars 模擬器︰ http://tryhandlebarsjs.com/ 另外, http://handlebarsjs.com/  這個好像是後續版本,但是設定不起來,說明也不清楚…只好by pass~   書中建議用handlebars,但實在覺得pug比較好用,所以決定還是用pug https://pugjs.org/api/getting-started.html pug to html 工具︰ http://html2pug.com/   關於node_modules被commit到git的問題 gitignore︰ https://github.com/github/gitignore/blob/master/Node.gitignore 將已commit的部份移除︰

[Sublime] 搜尋檔案中是否有使用IPv4

因為原server要搬移,導至IP會變,所以被求找出使用到的IP 這時候用Regular是最快的了~ 1. 首先去查查有沒有網友寫好的reguler 找到  http://www.regular-expressions.info/ip.html 簡單點,使用這個 \b(?:\d{1,3}\.){3}\d{1,3}\b 2. 以前都是用UltraEdit,但在Mac只好用sublime嘍 注意!這裡的Regular要寫成  (?:\d{1,3}\.){3}\d{1,3} 限制搜尋的檔案類型 多種類的話就一直加下去︰ /Users/kirk/Documents/Projects/,*.h,*.m,*.swift,*.xml 以上~

[佳句]

  韋恩.格雷耶基(Wayne Gretzky)的成功 並不是因為他滑向冰球 而是因為他滑向冰球滾動的方向     分享自雪倫的文章 「沒安全感,其實只是你害怕面對不想要的結果」

[MAC] spotlight 不能搜尋了!!

Spotlight其實不常用,但Alfred不能用就有點跛腳了~ 解法︰ 輸入以下指令,關掉索引 sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.metadata.mds.plist   輸入以下指令,重新啟用索引 sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.metadata.mds.plist   參考︰ https://errerrors.blogspot.tw/2016/01/mac-spotlight.html

[SEO] 關於 Google 不到自己的 Blogger 這件事

查了一下網路上的說法,大概就是 title, h1, h2 這3個的問題 用下面的工具看一下,果然 h2 是沒資料的 Chrome工具: https://www.techcoke.com/2015/02/chrome-extension-open-seo-stats.html title: http://www.laird.tw/2015/06/seo-blogger-seo.html h1, h2: https://www.techcoke.com/2017/01/blogger-widgte-title-html-tag-seo.html 文章url, 搜尋說明: http://www.wfublog.com/2012/07/blogger-custom-post-url.html   Meta: https://kai73002981.blogspot.tw/2016/06/blogger-meta-tag.html  

[Java] equals 與 ==

今天被同事問到Java equals的問題,發現觀念已經有點模糊了…老啦 只記得數字就用==,字串就用equals,至於原因已經還給老師了 Sample: 一開始真的有點打結,不同的物件怎麼會有相同的hashCode…是我的記憶有了錯誤嗎XD 想不通只好各種解釋… String s1 = new String("ABC"); String s2 = new String("ABC"); System.out.println("s1." + s1 + ".hashCode:" + s1.hashCode()); System.out.println("s2." + s2 + ".hashCode:" + s2.hashCode()); if(s1.equals(s2)){ System.out.println("s1 is equals s2 !"); }else{ System.out.println("s1 is not equals s2 !"); } if(s1 == s2){ System.out.println("s1 = s2 !"); }else{ System.out.println("s1 != s2 !"); } Object o1 = new Object(); Object o2 = new Object(); System.out.println("o1." + o1 + ".hashCode:" + o1.hashCode()); System.out.println("o2." + o2 + ".hashCode:" + o2.hashCode()); if(o1.equals(o2)){ System.out.println("o1 is equals o2 !"); }else{ System.out.println("o1 is not equals o2 !"); } if(o1 =

[Python] 學習資源

IDE︰ Eclipse + PyDev 這個可以直接在Eclipse裡面安裝 http://tw.tonytuan.org/2011/04/python-eclipsepydev.html   語言教學︰ Python 2.7 https://openhome.cc/Gossip/CodeData/PythonTutorial/index.html https://github.com/JustinSDK/PyConTW2013Tutorial/blob/master/tutorial/PythonTutorial.MD Python 3 https://openhome.cc/Gossip/Python/ 通過例子說明Python 2.7.x和Python 3.x關鍵差異 https://kknews.cc/zh-tw/news/bl2mj.html   安裝Python︰ 原本Mac就有python2了,但朋友用的是Python3,所以還是來裝一下 看了幾篇網路上的教學後還是選擇用homebrew來裝,因為它簡單吶! # 先更新一下 brew update # 查詢是否已有安裝,到安裝目錄下看是否有python及python3 ls /usr/local/Cellar/ # 安裝python3 brew install python3 # 檢查系統路徑中/usr/local/bin是否在/usr/bin的前面,如果不是的話就調整一下 echo $PATH # 檢查python3是否在正確位置 which python3 參考︰   Mac OSX 正確地同時安裝 Python 2.7 和 Python3 https://stringpiggy.hpd.io/mac-osx-python3-dual-install/   使用Pyenv安裝不同版本Python https://medium.com/@hyWang/%E4%BD%BF%E7%94%A8pyenv%E5%AE%89%E8%A3%9D%E4%B8%8D%E5%90%8C%E7%89%88%E6%9C%ACpython-1d83a5164883 pyenv https://gist.github.com/Bouke/11261620   開發

[React Native] 筆記

1.安裝node.js 2.安裝watchman (https://facebook.github.io/watchman/docs/install.html) brew update brew install watchman 2.1修正Error Error: Cannot write to /usr/local/Cellar sudo chown -R $(whoami):admin /usr/local

[NodeJS] 建置記錄

1.建立新專案︰ $ express --view=pug nodeservice create : nodeservice create : nodeservice/package.json create : nodeservice/app.js create : nodeservice/public create : nodeservice/public/stylesheets create : nodeservice/public/stylesheets/style.css create : nodeservice/public/images create : nodeservice/routes create : nodeservice/routes/index.js create : nodeservice/routes/users.js create : nodeservice/public/javascripts create : nodeservice/views create : nodeservice/views/index.pug create : nodeservice/views/layout.pug create : nodeservice/views/error.pug create : nodeservice/bin create : nodeservice/bin/www install dependencies: $ cd nodeservice && npm install run the app: $ DEBUG=nodeservice:* npm start 2.安裝相依項目(install dependencies 同上面所寫) $ cd nodeservice && npm install 以下是目前會用的到,也一起安裝 npm install date-utils --save npm install fs --save npm install quick-local-ip --save npm install mongodb --save 3.在console.log上加上時間 在app.js上增加 require('date-utils');