Commit Graph

15 Commits

Author SHA1 Message Date
Edgars Eglītis 00cd1b4b0f fix(docutils): restore support for Python <3.12 (#20675)
* fix(docutils): restore support for Python <3.12

* fix(docutils): only add the pip flag when required

* chore: fix lint

* chore: tune version number validation

* chore: address review comments

* chore: use env var to handle any pip version

* chore: remove unused import

* docs: add the env variable to zh docs

* fix: pass env vars properly on Windows

* chore: improve readability
2024-10-19 00:07:30 +03:00
Edgars Eglītis 8d7cec96d8 fix(docutils): support Python 3.12+ (#20666) 2024-10-14 20:40:31 +03:00
renovate[bot] 8bfa1b5a4d fix(types): update dependency type-fest to v4 (#19104) 2023-12-05 22:51:55 +01:00
Edgars Eglītis 7528fcf890 fix(docutils): remove @appium/typedoc-plugin-appium and all other uses of typedoc (#19465) 2023-12-05 08:46:07 +01:00
Christopher Hiller 2766dcca4c feat(docutils): init: scafffold package.json
This makes `appium-docs init` add a needed prop (`typedoc.entryPoint`) to `package.json` of an extension. It will write to `package.json` _by default_, even if it exists--which is different than the default behavior of other scaffolding tasks.

Note that `appium-docs init` will now _fail_ if `--entry-point <some-file>` (or `-e`) is not provided; there's no way for us to guess what it is (this is the _source_ entry point; not necessarily the `main` file). I guess that's technically breaking, but `appium-docs init` should not be part of anyone's workflow.
2023-05-24 14:26:07 -07:00
Christopher Hiller 426830d14a fix(docutils): exec mike/mkdocs via python -m
- also adds a "custom typedoc path" option
- consolidate the `whichPython*` functions into a single `findPython` fn
2023-05-19 13:42:08 -07:00
Christopher Hiller 7b17754786 fix(docutils): try python3 if python not in PATH 2023-05-19 13:42:08 -07:00
Christopher Hiller e9426fcfec fix(docutils): properly respects log levels
The resulting solution keeps a bunch of weak refs to `Consola` objects and sets the log level on all of them if it ever changes.

This is--at minimum--easier to understand than the broken `Proxy` implementation.
2023-04-10 15:58:58 -07:00
Christopher Hiller 4cfad004db feat(docutils): add --upgrade flag to init
users can run `appium-docs init --upgrade` to upgrade python deps (e.g., mkdocs, mkdocs-material)
2023-03-07 14:27:16 -08:00
Christopher Hiller 58b4790b1d chore: lint all the typescript 2023-03-06 15:21:58 -08:00
Christopher Hiller 73ff1b8f3c fix(docutils): fix logic for 'include' prop of tsconfig.json 2023-02-02 16:25:45 -08:00
Christopher Hiller 5960cc89ac chore(docutils): break out fs-related functions in util into their own module 2023-02-02 16:25:45 -08:00
Christopher Hiller 93b5831e3a feat(docutils): add mkdocs output to build command
`build` now executes both `typedoc` and `mkdocs` unless options to one run or the other are passed.

- renamed `init-task` to `scaffold`
- renamed `build` to `typedoc`
- fix JSON5 stringification
- use typedoc's facilities for reading its own config files, which absolves us from having to expand the `extends` prop in `typedoc.json` (if any)
2023-02-02 16:25:45 -08:00
Christopher Hiller ab202aa673 feat(docutils): add "validate" command
The `validate` command checks the status of the environment and reports any problems to the user.

This includes Python env and dep checks, typescript and typedoc checks of installed version and configuration files (to varying degrees).

Also:

- Convert `mkdocs.js` to TS; remove `assertMkDocs` as that moved into the `validate` module
- JSON5 support for `tsconfig.json` (this is important, because the default `tsconfig.json` is a JSON5 file)
- Sorted the options in the `cli` module
- Renamed `types` to `model`
- Moved some constants into new module `constants`
2023-02-02 16:25:45 -08:00
Christopher Hiller 4955948651 feat(docutils): begin doc-generation cli
This provides some tools for extension authors to easily setup and configure their packages to build docs and create documentation via TypeDoc & mkdocs.
2023-02-02 16:25:45 -08:00