-
Notifications
You must be signed in to change notification settings - Fork 126
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Introduce configuration file support (#858)
* introducing configuration file * support for config file and custom .env location * added docs * simpler * updated docs * cleanup setting? * fix build * refactor: ♻️ update import for HostConfiguration module * feat: 🎉 add check for specific env file in syncDotEnv * removefd project file * typo
- Loading branch information
Showing
25 changed files
with
411 additions
and
458 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,3 +24,5 @@ dev/ | |
foobar*.genai.mjs | ||
azure-sdk-for-js/ | ||
trapi.md | ||
.env.local | ||
genaiscript.config.yaml |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1464,7 +1464,7 @@ available under the Apache 2.0 license (https://github.com/puppeteer/puppeteer/b | |
|
||
The following npm package may be included in this product: | ||
|
||
- [email protected].1 | ||
- [email protected].2 | ||
|
||
This package contains the following license: | ||
|
||
|
@@ -1702,7 +1702,7 @@ MIT License | |
|
||
The following npm package may be included in this product: | ||
|
||
- [email protected].0 | ||
- [email protected].1 | ||
|
||
This package contains the following license: | ||
|
||
|
@@ -3820,16 +3820,6 @@ IN THE SOFTWARE. | |
|
||
----------- | ||
|
||
The following npm package may be included in this product: | ||
|
||
- [email protected] | ||
|
||
This package contains the following license: | ||
|
||
http://github.com/mscdex/buildcheck/raw/master/LICENSE | ||
|
||
----------- | ||
|
||
The following npm package may be included in this product: | ||
|
||
- [email protected] | ||
|
@@ -3840,16 +3830,6 @@ http://github.com/mscdex/ssh2/raw/master/LICENSE | |
|
||
----------- | ||
|
||
The following npm package may be included in this product: | ||
|
||
- [email protected] | ||
|
||
This package contains the following license: | ||
|
||
https://github.com/mscdex/cpu-features/raw/master/LICENSE | ||
|
||
----------- | ||
|
||
The following npm packages may be included in this product: | ||
|
||
- [email protected] | ||
|
@@ -4582,12 +4562,12 @@ THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI | |
|
||
The following npm packages may be included in this product: | ||
|
||
- @esbuild/linux-x64@0.23.1 | ||
- @esbuild/win32-x64@0.23.1 | ||
- @tokenizer/token@0.3.0 | ||
- [email protected] | ||
- [email protected].0 | ||
- [email protected].0 | ||
- [email protected].0 | ||
- [email protected].1 | ||
- [email protected].1 | ||
- [email protected].1 | ||
- [email protected] | ||
- [email protected] | ||
- [email protected] | ||
|
@@ -5356,7 +5336,7 @@ SOFTWARE. | |
|
||
The following npm package may be included in this product: | ||
|
||
- [email protected].1 | ||
- [email protected].2 | ||
|
||
This package contains the following license: | ||
|
||
|
@@ -5514,7 +5494,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI | |
The following npm packages may be included in this product: | ||
|
||
- [email protected] | ||
- undici@6.20.1 | ||
- undici@6.21.0 | ||
|
||
These packages each contain the following license: | ||
|
||
|
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
title: Configuration Files | ||
description: Learn how to configure common configuration settings using configuration files | ||
sidebar: | ||
order: 90 | ||
--- | ||
|
||
import { Code } from "@astrojs/starlight/components" | ||
import hostConfigurationSource from "../../../../../packages/core/src/hostconfiguration.ts?raw" | ||
|
||
GenAIScript supports local and global configuration files to allow reusing common configuration settings and secrets across multiple scripts. | ||
|
||
## File resolution | ||
|
||
GenAIScript will scan for the following configuration files | ||
and merge their content into the final configuration. | ||
|
||
- `~/genaiscript.config.yaml` | ||
- `~/genaiscript.config.json` | ||
- `./genaiscript.config.yaml` | ||
- `./genaiscript.config.json` | ||
|
||
## File format | ||
|
||
The configuration file format is the following: | ||
|
||
<Code code={hostConfigurationSource} wrap={true} lang="ts" /> | ||
|
||
The final location of `envFile` will be used to load the secret in the environment variables. |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.