Merge pull request #60 from AshishBarvaliya/feat/gpt4 #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jobs: | |
build-and-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: "16" | |
- name: Install Dependencies | |
run: npm install | |
- name: Create .env file | |
run: | | |
echo "OPENAI_API_KEY=${{ secrets.OPENAI_API_KEY }}" >> .env | |
echo "DRIZZLE_DATABASE_URL=${{ secrets.DRIZZLE_DATABASE_URL }}" > .env | |
echo "NEXTAUTH_SECRET=${{ secrets.NEXTAUTH_SECRET }}" >> .env | |
echo "NEXTAUTH_URL=${{ secrets.NEXTAUTH_URL }}" >> .env | |
echo "GOOGLE_CLIENT_ID=${{ secrets.GOOGLE_CLIENT_ID }}" >> .env | |
echo "GOOGLE_CLIENT_SECRET=${{ secrets.GOOGLE_CLIENT_SECRET }}" >> .env | |
echo "NODE_ENV=${{ secrets.NODE_ENV }}" >> .env | |
echo "STRIPE_PRICE_ID=${{ secrets.STRIPE_PRICE_ID }}" >> .env | |
echo "STRIPE_SECRET_KEY=${{ secrets.STRIPE_SECRET_KEY }}" >> .env | |
echo "PUPU_PER_PURCHASE=${{ secrets.PUPU_PER_PURCHASE }}" >> .env | |
echo "VERIFICATION_MAIL_LIMIT=${{ secrets.VERIFICATION_MAIL_LIMIT }}" >> .env | |
echo "FORGOT_PASSWORD_MAIL_LIMIT=${{ secrets.FORGOT_PASSWORD_MAIL_LIMIT }}" >> .env | |
echo "EMAIL_LINK_EXPIRY=${{ secrets.EMAIL_LINK_EXPIRY }}" >> .env | |
echo "THEMES_PER_PAGE=${{ secrets.THEMES_PER_PAGE }}" >> .env | |
- name: Build | |
run: npm run build | |
- name: Create .env.test file | |
run: | | |
echo "DRIZZLE_DATABASE_URL=${{ secrets.DRIZZLE_TEST_DATABASE_URL }}" > .env.test | |
- name: Run Unit Tests | |
run: npm test |