mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-04-13 00:09:02 +08:00
Updated Developing extensions (markdown)
parent
4ed7cf353e
commit
ed03b2b6ff
@ -16,13 +16,18 @@ For how to develop custom scripts, which usually will do most of extension's wor
|
||||
The preferred way to do localizations for the project is via making an extension. The basic file structure for the extension should be:
|
||||
|
||||
```
|
||||
๐ localization-la_LA
|
||||
โโโ ๐ localization
|
||||
โโโ ๐ la_LA.json
|
||||
|
||||
๐ webui root directory
|
||||
โโโ ๐ extensions
|
||||
โโโ ๐ webui-localization-la_LA <----- name of extension
|
||||
โโโ ๐ localization <----- the single directory inside the extension
|
||||
โโโ ๐ la_LA.json <----- actual file with translations
|
||||
```
|
||||
|
||||
Create a github repository with this file structure and ask any of people listed in collaborators section to add your extension to wiki.
|
||||
|
||||
If your language needs javascript/css or even python support, you can add that to the extension too.
|
||||
|
||||
## install.py
|
||||
`install.py` is the script that is launched by the `launch.py`, the launcher, in a separate process before webui starts, and it's meant to install dependencies of the extension. It must be located in the root directory of the extension, not in the scripts directory. The script is launched with `PYTHONPATH` environment variable set to webui's path, so you can just `import launch` and use its functionality:
|
||||
|
||||
|
Loadingโฆ
x
Reference in New Issue
Block a user