Skip to content

Commit 8f8ad98

Browse files
authored
Merge branch 'main' into add-editor-tools-contrib-page
2 parents 535f9cc + 5e23c92 commit 8f8ad98

File tree

703 files changed

+5524
-4220
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

703 files changed

+5524
-4220
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@ jobs:
55
build:
66
runs-on: ubuntu-latest
77
steps:
8-
- uses: actions/checkout@v2
8+
- uses: actions/checkout@v4.1.2
99

1010
- name: Setup Node
11-
uses: actions/setup-node@v3.8.1
11+
uses: actions/setup-node@v4.0.2
1212
with:
13-
node-version: '18'
13+
node-version: 20
1414

1515
- run: npm install
1616
# - run: npm run build

.github/workflows/command-block.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
comment:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/github-script@v6
11+
- uses: actions/github-script@v7.0.1
1212
with:
1313
script: |
1414
github.rest.issues.createComment({
@@ -21,5 +21,3 @@ jobs:
2121
'- Else, please look for the command in the [source tree](https://github.com/nushell/nushell/tree/main/crates) and make your changes directly there.\n\n'+
2222
'Thanks for helping out!'
2323
})
24-
25-

.github/workflows/deploy.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@ jobs:
1111
runs-on: ubuntu-latest
1212
if: ${{ github.event_name == 'push' }}
1313
steps:
14-
- uses: actions/checkout@v3
14+
- uses: actions/checkout@v4.1.2
1515
with:
1616
ref: main
1717
fetch-depth: 0
1818

1919
- name: Setup Node
20-
uses: actions/setup-node@v3.8.1
20+
uses: actions/setup-node@v4.0.2
2121
with:
22-
node-version: '18'
22+
node-version: 20
2323

2424
- run: npm install
2525
- name: Build Static Docs
@@ -28,7 +28,7 @@ jobs:
2828
run: npm run build
2929

3030
- name: Upload Artifact
31-
uses: actions/upload-pages-artifact@v2
31+
uses: actions/upload-pages-artifact@v3.0.1
3232
with:
3333
path: ./.vuepress/dist
3434

@@ -46,4 +46,4 @@ jobs:
4646
steps:
4747
- name: Deploy to GitHub Pages
4848
id: deployment
49-
uses: actions/deploy-pages@v2.0.4
49+
uses: actions/deploy-pages@v4.0.5

.github/workflows/image-actions.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: Checkout Repo
17-
uses: actions/checkout@v3
17+
uses: actions/checkout@v4.1.2
1818
- name: Compress Images
1919
id: calibre
2020
uses: calibreapp/image-actions@main
@@ -30,7 +30,7 @@ jobs:
3030
githubToken: ${{ secrets.GITHUB_TOKEN }}
3131
- name: Create New Pull Request If Needed
3232
if: steps.calibre.outputs.markdown != ''
33-
uses: peter-evans/create-pull-request@v3
33+
uses: peter-evans/create-pull-request@v6.0.3
3434
with:
3535
title: Compressed Images
3636
branch-suffix: timestamp

.github/workflows/typos.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- name: Checkout Actions Repository
10-
uses: actions/checkout@v2
10+
uses: actions/checkout@v4.1.2
1111

1212
- name: Check spelling
1313
uses: crate-ci/typos@master

.vuepress/client.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* https://v2.vuepress.vuejs.org/advanced/cookbook/usage-of-client-config.html
55
*/
66

7-
import { defineClientConfig } from '@vuepress/client';
7+
import { defineClientConfig } from 'vuepress/client';
88
import BlogPosts from './components/BlogPosts.vue';
99

1010
export default defineClientConfig({

.vuepress/config.js

Lines changed: 27 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
import path from 'path';
22
import { defineUserConfig } from '@vuepress/cli';
33
import { gitPlugin } from '@vuepress/plugin-git';
4-
import { feedPlugin } from 'vuepress-plugin-feed2';
4+
import { feedPlugin } from '@vuepress/plugin-feed';
5+
import { viteBundler } from '@vuepress/bundler-vite';
56
import { shikiPlugin } from '@vuepress/plugin-shiki';
67
import { defaultTheme } from '@vuepress/theme-default';
7-
import { sitemapPlugin } from 'vuepress-plugin-sitemap2';
8+
import { sitemapPlugin } from '@vuepress/plugin-sitemap';
9+
import { copyCodePlugin } from '@vuepress/plugin-copy-code';
810
import { docsearchPlugin } from '@vuepress/plugin-docsearch';
911
import { backToTopPlugin } from '@vuepress/plugin-back-to-top';
1012
import { mediumZoomPlugin } from '@vuepress/plugin-medium-zoom';
@@ -33,10 +35,19 @@ const compareDate = (dateA, dateB) => {
3335
return dateB.getTime() - dateA.getTime();
3436
};
3537

38+
// default env from the deploy GitHub action
39+
// e.g. ciUser = nushell and ciRepo = nushell.github.io
40+
// both default to undefined if the env is undefined
41+
const [ciUser, ciRepo] = process.env.GITHUB_REPOSITORY?.split('/') ?? [];
42+
3643
export default defineUserConfig({
44+
// set the base URL to ciRepo dir if it's a fork
45+
// keep the default root if not
46+
base: ciRepo && ciUser !== 'nushell' ? `/${ciRepo}/` : '/',
47+
bundler: viteBundler(),
3748
locales: {
3849
'/': {
39-
lang: 'English',
50+
lang: 'en-US',
4051
title: 'Nushell',
4152
description: 'A new type of shell.',
4253
},
@@ -46,17 +57,17 @@ export default defineUserConfig({
4657
description: '一种新型的Shell',
4758
},
4859
'/de/': {
49-
lang: 'Deutsch',
60+
lang: 'de-DE',
5061
title: 'Nushell',
5162
description: 'Eine neue Art von Shell.',
5263
},
5364
'/es/': {
54-
lang: 'es',
65+
lang: 'es-ES',
5566
title: 'Nushell',
5667
description: 'Un nuevo tipo de shell.',
5768
},
5869
'/ja/': {
59-
lang: 'ja',
70+
lang: 'ja-JP',
6071
title: 'Nushell',
6172
description: '新しいタイプのシェル',
6273
},
@@ -66,7 +77,7 @@ export default defineUserConfig({
6677
description: 'Um novo tipo de shell.',
6778
},
6879
'/ru': {
69-
lang: 'ru',
80+
lang: 'ru-RU',
7081
title: 'Nushell',
7182
description: 'Новый тип оболочки.',
7283
},
@@ -91,6 +102,7 @@ export default defineUserConfig({
91102
},
92103
// without this, we attempt to prefetch the whole site 😬
93104
shouldPrefetch: false,
105+
colorMode: 'auto',
94106
theme: defaultTheme({
95107
repo: 'nushell/nushell',
96108
repoLabel: 'GitHub',
@@ -134,7 +146,7 @@ export default defineUserConfig({
134146
navbar: navbarPtBR,
135147
sidebar: sidebarPtBR,
136148
},
137-
'/ru': {
149+
'/ru/': {
138150
selectText: 'Языки',
139151
selectLanguageName: 'Русский язык',
140152
editLinkText: 'Отредактируйте эту страницу на GitHub',
@@ -154,6 +166,13 @@ export default defineUserConfig({
154166
gitPlugin(),
155167
backToTopPlugin(),
156168
mediumZoomPlugin(),
169+
copyCodePlugin({
170+
locales: {
171+
'/': {
172+
copy: 'Copy Codes from code block',
173+
},
174+
},
175+
}),
157176
shikiPlugin({
158177
theme: 'dark-plus',
159178
langs: [

.vuepress/configs/sidebar/en.ts

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -118,13 +118,13 @@ export const sidebarEn: SidebarConfig = {
118118
link: '/contributor-book/README.md',
119119
collapsible: false,
120120
children: [
121-
'README.md',
122-
'philosophy',
123-
'philosophy_0_80',
124-
'commands',
125-
'plugins',
126-
'plugin_protocol_reference',
127-
'parser_and_other_editor_tools.md',
121+
'/contributor-book/README.md',
122+
'/contributor-book/philosophy',
123+
'/contributor-book/philosophy_0_80',
124+
'/contributor-book/commands',
125+
'/contributor-book/plugins',
126+
'/contributor-book/plugin_protocol_reference',
127+
'/contributor-book/parser_and_other_editor_tools.md',
128128
],
129129
},
130130
],
@@ -133,23 +133,23 @@ export const sidebarEn: SidebarConfig = {
133133
text: 'Cookbook',
134134
collapsible: false,
135135
children: [
136-
'README.md',
137-
'setup',
138-
'help',
139-
'system',
140-
'parsing',
141-
'foreign_shell_scripts',
142-
'pattern_matching',
143-
'external_completers',
144-
'files',
145-
'git',
146-
'parsing_git_log',
147-
'http',
148-
'direnv',
149-
'ssh_agent',
150-
'tables',
151-
'polars_v_pandas_v_nushell',
152-
'jq_v_nushell',
136+
'/cookbook/README.md',
137+
'/cookbook/setup',
138+
'/cookbook/help',
139+
'/cookbook/system',
140+
'/cookbook/parsing',
141+
'/cookbook/foreign_shell_scripts',
142+
'/cookbook/pattern_matching',
143+
'/cookbook/external_completers',
144+
'/cookbook/files',
145+
'/cookbook/git',
146+
'/cookbook/parsing_git_log',
147+
'/cookbook/http',
148+
'/cookbook/direnv',
149+
'/cookbook/ssh_agent',
150+
'/cookbook/tables',
151+
'/cookbook/polars_v_pandas_v_nushell',
152+
'/cookbook/jq_v_nushell',
153153
],
154154
},
155155
],
@@ -158,7 +158,7 @@ export const sidebarEn: SidebarConfig = {
158158
text: 'Language Reference Guide',
159159
link: '/lang-guide/README.md',
160160
collapsible: false,
161-
children: ['README.md', 'lang-guide.md'],
161+
children: ['/lang-guide/README.md', '/lang-guide/lang-guide.md'],
162162
},
163163
],
164164
};

.vuepress/configs/sidebar/es.ts

Lines changed: 20 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -6,27 +6,26 @@ export const sidebarEs: SidebarConfig = {
66
text: 'Nu Libro',
77
collapsible: false,
88
children: [
9-
'README.md',
10-
'instalacion',
11-
'explorando',
12-
'tipos_de_datos',
13-
'cargando_datos', // "trabajando_con_listas"
14-
'trabajando_con_tablas',
15-
'pipeline',
16-
'configuracion', // "custom_commands"
17-
'aliases', // "operadores"
18-
'matematicas', // "variables_y_subexpresiones"
19-
'entorno', // "scripts"
20-
'metadatos',
21-
'shells_en_shells',
22-
'escapando',
23-
'plugins', // "dataframes"
24-
'llegando_de_bash',
25-
'mapa_nushell',
26-
'mapa_imperativo_nushell',
27-
'mapa_funcional_nushell',
28-
'mapa_operador_nushell',
29-
'/book/command_reference.md',
9+
'/es/book/README.md',
10+
'/es/book/instalacion',
11+
'/es/book/explorando',
12+
'/es/book/tipos_de_datos',
13+
'/es/book/cargando_datos', // "trabajando_con_listas"
14+
'/es/book/trabajando_con_tablas',
15+
'/es/book/pipeline',
16+
'/es/book/configuracion', // "custom_commands"
17+
'/es/book/aliases', // "operadores"
18+
'/es/book/matematicas', // "variables_y_subexpresiones"
19+
'/es/book/entorno', // "scripts"
20+
'/es/book/metadatos',
21+
'/es/book/shells_en_shells',
22+
'/es/book/escapando',
23+
'/es/book/plugins', // "dataframes"
24+
'/es/book/llegando_de_bash',
25+
'/es/book/mapa_nushell',
26+
'/es/book/mapa_imperativo_nushell',
27+
'/es/book/mapa_funcional_nushell',
28+
'/es/book/mapa_operador_nushell',
3029
],
3130
},
3231
],

.vuepress/configs/sidebar/pt-BR.ts

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,18 @@ export const sidebarPtBR: SidebarConfig = {
66
text: 'Nu Livro',
77
collapsible: false,
88
children: [
9-
'instalacao',
10-
'introducao',
11-
'explorando',
12-
'tipos_de_dados',
13-
'carregando_dados',
14-
'trabalhando_com_tabelas',
15-
'pipeline',
16-
'line_editor',
17-
'metadados',
18-
'shells_em_shells',
19-
'escapando',
20-
'plugins',
9+
'/pt-BR/book/instalacao',
10+
'/pt-BR/book/introducao',
11+
'/pt-BR/book/explorando',
12+
'/pt-BR/book/tipos_de_dados',
13+
'/pt-BR/book/carregando_dados',
14+
'/pt-BR/book/trabalhando_com_tabelas',
15+
'/pt-BR/book/pipeline',
16+
'/pt-BR/book/line_editor',
17+
'/pt-BR/book/metadados',
18+
'/pt-BR/book/shells_em_shells',
19+
'/pt-BR/book/escapando',
20+
'/pt-BR/book/plugins',
2121
],
2222
},
2323
],

0 commit comments

Comments
 (0)