mirror of
https://github.com/slint-ui/slint.git
synced 2025-10-01 06:11:16 +00:00
docs: Move slint language docs from langref to language folder
This commit is contained in:
parent
39d215bee0
commit
0867aa1ed9
47 changed files with 7 additions and 7 deletions
|
@ -48,7 +48,7 @@
|
|||
},
|
||||
{
|
||||
"languageId": "restructuredtext",
|
||||
"words": ["genindex", "langref", "modindex", "toctree"],
|
||||
"words": ["genindex", "modindex", "toctree"],
|
||||
"ignoreRegExpList": ["/:.+:/"]
|
||||
},
|
||||
{
|
||||
|
|
|
@ -10,7 +10,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
|
|||
let mut tests_file = std::fs::File::create(&tests_file_path)?;
|
||||
|
||||
let prefix = Path::new(env!("CARGO_MANIFEST_DIR")).join("../..").canonicalize()?;
|
||||
for entry in std::fs::read_dir(prefix.join("docs/langref/src"))?
|
||||
for entry in std::fs::read_dir(prefix.join("docs/language/src"))?
|
||||
.chain(std::fs::read_dir(prefix.join("docs"))?)
|
||||
.chain(std::fs::read_dir(prefix.join("docs/recipes"))?)
|
||||
{
|
||||
|
|
|
@ -38,7 +38,7 @@ pub fn generate() -> Result<(), Box<dyn std::error::Error>> {
|
|||
|
||||
let root = super::root_dir();
|
||||
|
||||
let path = root.join("docs/langref/src/builtin_enums.md");
|
||||
let path = root.join("docs/language/src/builtin_enums.md");
|
||||
let mut file = std::fs::File::create(&path).context(format!("error creating {path:?}"))?;
|
||||
|
||||
file.write_all(
|
||||
|
|
|
@ -273,8 +273,8 @@ lazy_static! {
|
|||
("^\\.reuse/dep5$", LicenseLocation::NoLicense), // .reuse files have no license headers
|
||||
("^api/cpp/docs/Pipfile$", LicenseLocation::NoLicense),
|
||||
("^api/cpp/docs/conf.py$", LicenseLocation::NoLicense),
|
||||
("^docs/langref/Pipfile$", LicenseLocation::NoLicense),
|
||||
("^docs/langref/conf.py$", LicenseLocation::NoLicense),
|
||||
("^docs/language/Pipfile$", LicenseLocation::NoLicense),
|
||||
("^docs/language/conf.py$", LicenseLocation::NoLicense),
|
||||
("^editors/tree-sitter-slint/binding.gyp$", LicenseLocation::NoLicense), // liberal license
|
||||
("^editors/tree-sitter-slint/test-to-corpus.py$", LicenseLocation::Tag(LicenseTagStyle::shell_comment_style())),
|
||||
("^editors/tree-sitter-slint/corpus/", LicenseLocation::NoLicense), // liberal license
|
||||
|
|
|
@ -58,7 +58,7 @@ fn symlink_files_in_dir<S: AsRef<Path>, T: AsRef<Path>, TS: AsRef<Path>>(
|
|||
pub fn generate(show_warnings: bool) -> Result<(), Box<dyn std::error::Error>> {
|
||||
let root = super::root_dir();
|
||||
|
||||
let docs_source_dir = root.join("docs/langref");
|
||||
let docs_source_dir = root.join("docs/language");
|
||||
let docs_build_dir = root.join("target/slintdocs");
|
||||
let html_static_dir = docs_build_dir.join("_static");
|
||||
|
||||
|
@ -69,7 +69,7 @@ pub fn generate(show_warnings: bool) -> Result<(), Box<dyn std::error::Error>> {
|
|||
symlink_files_in_dir(
|
||||
&docs_source_dir,
|
||||
&docs_build_dir,
|
||||
["..", "..", "docs", "langref"].iter().collect::<PathBuf>(),
|
||||
["..", "..", "docs", "language"].iter().collect::<PathBuf>(),
|
||||
)
|
||||
.context(format!("Error creating symlinks from docs source {docs_source_dir:?} to docs build dir {docs_build_dir:?}"))?;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue