add: docs (mainly docstrings)

This commit is contained in:
Wataru Otsubo 2024-09-14 23:48:15 +09:00
parent 4f88659288
commit 1dd48e703e
5 changed files with 126 additions and 8 deletions

View file

@ -8,7 +8,10 @@ DocMeta.setdocmeta!(
recursive = true,
)
links = InterLinks("DataFrames" => "https://dataframes.juliadata.org/dev/objects.inv")
links = InterLinks(
"DataFrames" => "https://dataframes.juliadata.org/dev/objects.inv",
"Dates" => "https://docs.julialang.org/en/v1/objects.inv",
)
makedocs(
modules = [PSBoardDataBase],

View file

@ -6,14 +6,35 @@ CurrentModule = PSBoardDataBase
このリポジトリにあるのは、JATHub masterのログファイル、及びGoogle SheetsからエクスポートしたCSVファイルからデータベースを作成するためのコードである。
メインの関数は[`create_database_from_exported_csvs`](@ref)である。
## テストについて
## 動かし方
[Julia](https://julialang.org)は[juliaup](https://github.com/JuliaLang/juliaup)でインストールする。
リポジトリのルート(`Project.toml`がある)で
```
$ julia --project
```
をするとJuliaのREPLが立ち上がる。
`]`をおして`Pkg`モードに入り、`instantiate`を実行すると、必要なパッケージを自動でインストールする。
backspaceでjulianモードに戻り(左側が`julia>`になってる)、`using PSBoardDataBase`をすると使えるようになる。
`?`を押すとhelpモードに入り、関数名などをいれるとそのドキュメント(下にあるものと同じ)が閲覧できる。
`PSBoardDataBase.create_database_from_exported_csvs`を検索すると使い方がわかる。
# テストについて
テストでは実際にデータベースを作成している。
デフォルトでは全部は実行しないが、master log fileをおき、かつ環境変数`LOCAL_TEST`を設定することで、master log fileが必要な工程まで含めて実行できる。[^1]
[^1]: master log fileはgitには入れたくないので、このような形態をとっている。
## API
# 新しいQAQCキャンペーン時に更新すべき内容
- [`PSBoardDataBase.insert_qaqc_campaign_id`](@ref): キャンペーンの日時
- [`PSBoardDataBase.get_campaign_id_from_run_id`](@ref): runidとの関係
# API
```@index
```
@ -22,7 +43,7 @@ CurrentModule = PSBoardDataBase
Modules = [PSBoardDataBase]
```
### `QaqcMasterLog`
## `QaqcMasterLog`
```@autodocs
Modules = [QaqcMasterLog]