Skip to content

Commit

Permalink
gha for twitter langchain
Browse files Browse the repository at this point in the history
  • Loading branch information
stat committed Dec 6, 2024
1 parent f3d419c commit abc15e4
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 1 deletion.
20 changes: 19 additions & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,22 @@ jobs:
run: |
npm install
npm run lint
npm run format
npm run format
lint-twitter-langchain:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "18"
cache: "npm"
# Install dependencies in parent directory first
- run: npm install
# Then install and lint in working directory
- name: Install and lint twitter-langchain
working-directory: ./twitter-langchain
run: |
npm install
npm run lint
npm run format
6 changes: 6 additions & 0 deletions .github/workflows/publish_docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@ jobs:
mkdir -p docs/cdp-langchain
cp -r cdp-langchain/docs/* docs/cdp-langchain/
# Move twitter-langchain docs
- name: Build Twitter LangChain docs
run: |
mkdir -p docs/twitter-langchain
cp -r twitter-langchain/docs/* docs/twitter-langchain/
# Deploy to GitHub Pages
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
Expand Down
24 changes: 24 additions & 0 deletions .github/workflows/publish_twitter_langchain.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Publish Twitter LangChain to NPM

on:
workflow_dispatch:

jobs:
deploy-twitter-langchain:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "18"
registry-url: "https://registry.npmjs.org"
- run: npm i && npm run build
- name: Install, build and publish Twitter (X) langchain
working-directory: ./twitter-langchain
run: |
npm publish --ignore-scripts --provenance --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit abc15e4

Please sign in to comment.