發表文章

目前顯示的是 7月, 2018的文章

ssh 出現 error in libcrypto Connection closed 錯誤訊息

 最近公司的產品OS更換到Alma Linux,因此安裝了一台全新的Alma Linux機器,然後接下來要使用scp去別的主機搬移檔案的時候出現了下面的錯誤訊息 The authenticity of host '10.*.*.68 (10.*.*.68)' can't be established. RSA key fingerprint is SHA256:RKJMaNXf4Fw5I2rjsdiLr17MQn1LTyMurlb6hV2qo18. This key is not known by any other names Are you sure you want to continue connecting (yes/no/[fingerprint])? yes Warning: Permanently added '10.*.*.68' (RSA) to the list of known hosts. ssh_dispatch_run_fatal: Connection to 10.*.*.68 port 22: error in libcrypto Connection closed 解決方法是指定加密演算法 update-crypto-policies --set DEFAULT:SHA1

Android -- 指定預設的activity

指定預設的activity作法 是進入Mainifest.xml檔案中於想要active的activity插入下面的tag即可 <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter>

Android Studio 出現 Failed to load AppCompat ActionBar with unknown error. 錯誤排除方式

圖片
最近開始進行 Android 開發專案,順便學習kotlin 語法,於是在主力開發機上面安裝Android Studio 3.x版本進行開發,結果正當快樂進行hello word的時候 發現奇怪的狀況,怎麼design view 上面空白一片(圖一),就算xml裡面已經有 textview 物件 還是空白,這時發現編輯器旁邊有錯誤提醒,訊息為 Failed to load AppCompat ActionBar with unknown error. 後來去google一下,大致上是/res/values/styles.xml 裡面有個布景設定的路徑沒有完全,少了Base在前面,如下圖 補上之後 再回去 design view 就可以看到已經恢復正常。 (圖一)