Featured image of post 在 IntelliJ IDEA 中使用 GitHub Copilot

在 IntelliJ IDEA 中使用 GitHub Copilot

簡介

GitHub Copilot 是由 GitHub 開發的基於 AI 的程式碼完成工具。 您可以透過在開發環境 IntelliJ IDEA 中安裝 GitHub Copilot 外掛程式來在 IntelliJ IDEA 中使用 GitHub Copilot。 啟動需要 GitHub 帳戶。

安裝方法

  1. 從 IntelliJ IDEA 的 File 選單中選擇 Settings
  2. 選擇 Plugins,在搜尋框中搜尋 “GitHub Copilot” img.png
  3. 從安裝按鈕進行安裝 img_1.png
  4. 點擊 Restart IDE 按鈕重新啟動 IntelliJ IDEA img_2.png img_3.png 重新啟動 IntelliJ IDEA 後,安裝即完成。

啟動

  1. 點擊右下角的圖示
  2. 點擊 Login to Github img_4.png
  3. 點擊 Copy and Open 按鈕 img_6.png
  4. 瀏覽器將開啟,如果您尚未登入 GitHub,請先登入,然後使用 Ctrl+V 貼上程式碼,並點擊 Continue 按鈕 img_7.png
  5. 點擊 Authorize GitHub Copilot Plugin 按鈕 img_8.png img_9.png 如果顯示上述畫面,則啟動完成。

試用看看

img_10.png 當您在 IntelliJ IDEA 編輯器中輸入幾個字元時,GitHub Copilot 將開始建議程式碼的後續部分。 享受 AI 強大的自動完成功能吧!

comments powered by Disqus
使用 Hugo 建立
主題 StackJimmy 設計