Skip to content

Commit

Permalink
Merge branch 'newrelic:develop' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
ndesai-newrelic committed Feb 21, 2024
2 parents 18e2ed5 + 980b6ff commit 54ae72e
Show file tree
Hide file tree
Showing 1,075 changed files with 56,305 additions and 54,296 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/agent-release-notes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: Setup node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- run: yarn install --frozen-lockfile

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Setup node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Install dependencies
run: yarn install --frozen-lockfile
Expand Down
39 changes: 39 additions & 0 deletions .github/workflows/trigger-i18n-merge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Trigger i18n merge

on:
pull_request:
branches:
- main
types:
- closed

jobs:
merge-main-i18n-branches:
name: Merge main to i18n branches
runs-on: ubuntu-latest
if: github.event.pull_request.merged == true
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Setup Node.js
uses: actions/setup-node@v3

- name: Cache dependencies
id: yarn-cache
uses: actions/cache@v3
with:
path: '**/node_modules'
key: ${{ runner.os }}-node-modules-${{ hashFiles('**/yarn.lock') }}

- name: Install dependencies
if: steps.yarn-cache.outputs.cache-hit != 'true'
run: yarn install --frozen-lockfile

- name: Check for modified files & merge
env:
GITHUB_TOKEN: ${{ secrets.DEVEX_OPENSOURCE_BOT_TOKEN }}
SOURCE_REF: ${{ github.ref }}
run: |
URL="https://api.github.com/repos/${GITHUB_REPOSITORY}/pulls/${{ github.event.pull_request.number }}/files"
yarn trigger-i18n-merge -u $URL
2 changes: 1 addition & 1 deletion .github/workflows/update-attribute-dictionary-json.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Get current date
id: date
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-whats-new-ids.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
- name: Setup node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Install dependencies
run: yarn add vfile-glob@1.0.0 to-vfile@6.1.0
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/validate-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Cache dependencies
id: yarn-cache
Expand All @@ -49,7 +49,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Cache dependencies
id: yarn-cache
Expand All @@ -75,7 +75,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Cache dependencies
id: yarn-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/validate-release-notes-json.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Cache dependencies
id: yarn-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/verify-mdx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Cache dependencies
id: yarn-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/webdriver.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 16
node-version: 18

- name: Cache dependencies
id: yarn-cache
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
16
18
18 changes: 18 additions & 0 deletions env.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/**
* since our English site serves content from our i18n sites,
* assets on those sites need to be prefixed with their site URL,
* otherwise they'll fail to load.
*/
const assetPrefix = () => {
if (process.env.BUILD_LANG === 'jp') {
return 'https://docs-website-jp.netlify.app';
}
if (process.env.BUILD_LANG === 'kr') {
return 'https://docs-website-kr.netlify.app';
}
return '';
};

module.exports = {
assetPrefix,
};
4 changes: 3 additions & 1 deletion gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ const parse = require('rehype-parse');
const unified = require('unified');
const rehypeStringify = require('rehype-stringify');
const addAbsoluteImagePath = require('./rehype-plugins/utils/addAbsoluteImagePath');
const { assetPrefix } = require('./env');

const siteUrl = 'https://docs.newrelic.com';
const additionalLocales = ['jp', 'kr'];
Expand Down Expand Up @@ -44,6 +45,7 @@ module.exports = {
DEV_SSR: true,
PRESERVE_FILE_DOWNLOAD_CACHE: true,
},
assetPrefix: assetPrefix(),
siteMetadata: {
title: 'New Relic Documentation',
titleTemplate: '%s | New Relic Documentation',
Expand All @@ -56,6 +58,7 @@ module.exports = {
'https://docs.newrelic.com/docs/style-guide/writing-guidelines/create-edit-content/',
},
plugins: [
`gatsby-plugin-netlify`,
'gatsby-plugin-react-helmet',
{
resolve: `gatsby-source-filesystem`,
Expand Down Expand Up @@ -321,7 +324,6 @@ module.exports = {

'gatsby-source-nav',
'gatsby-source-install-config',
'gatsby-plugin-meta-redirect',
{
resolve: 'gatsby-plugin-gatsby-cloud',
options: {
Expand Down

0 comments on commit 54ae72e

Please sign in to comment.