Skip to content

Instantly share code, notes, and snippets.

View grady982's full-sized avatar
🌴
On vacation

Grady Liu grady982

🌴
On vacation
View GitHub Profile
@grady982
grady982 / VS_Code.md
Created September 24, 2025 17:07
MCP Learning Notes

Use MCP servers in VS Code

https://code.visualstudio.com/docs/copilot/customization/mcp-servers#_add-an-mcp-server-to-your-workspace

VS Code acts as an MCP client, allowing you to use AI tools like GitHub Copilot within it. To query your Figma project, you need to install the Figma MCP Server, so that the AI tool (e.g., GitHub Copilot) can interact with Figma through the Model Context Protocol (MCP).

Install MCP Servers Extensions

  1. Open VS Code > Open Extensions > type @mcp > click Browse MCP Servers
  2. You will open the MCP Registry website
@grady982
grady982 / java-17.bat
Last active February 21, 2025 05:26
Siwtch Java version on Windows
@echo off
set JAVA_HOME=C:\Program Files\Java\jdk-17
set PATH=%JAVA_HOME%\bin;%PATH%
echo Display Java Version
java -version
mvn -version

Delete node_modules like a Pro

npx npkill

find the all node_modules in file system

Issue: HTTP Request Payload With Date Filed

I found out the Date field value was not correct while I sent it to the backend.

Browser Console

 {
   start: Thu Jan 04 2024 00:00:00 GMT+0800 (Taipei Standard Time), 
 end: Thu Jan 04 2024 23:59:00 GMT+0800 (Taipei Standard Time)
@grady982
grady982 / README.md
Last active December 20, 2023 07:36
Angular Meterial Table with virtual scrolling and multiple header
@grady982
grady982 / Embeded Tableau View In Angular.md
Last active October 30, 2024 08:41
Embeded Tableau View

Tableau Embedded in Angular

在 Angular 中嵌入 Tableau Report 需要解決以下幾點:

  1. Tableau 嵌入代碼
  2. Tableau 嵌入身分驗證(Connected Apps)
  3. 產出 Tableau 信任的 Token(JWT)

Tableau 嵌入代碼

@grady982
grady982 / Airflow.md
Last active October 30, 2024 06:02
Airflow

REF

What is Airflow

Manage complex workflows;Workflow management platform 工作流程管理平台

Workflow is a sequence of tasks. In aifflow, workflow is defined as DAG.

工作流程是一個序列化的任務清單,工作流程定義為 DAG

ORM: N + 1 query problem

ORM 在 query 結果時因為 entity 與 entity 之間的關聯, 造成資料重複往返 entity 做搜尋

case:

select * from recipes
select * from ingredients where recipes_id = ?
select * from ingredients where recipes_id = ?

CICD

  • CI: continuous itergration
  • CD: continuous delivery
  • pipeline: 根據不同階段執行不同任務

gitlab cicd config 設定

runner 會根據 .gitlab-ci.yml config 設定去執行