Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@
[submodule "syntax-highlighting/sublime_toml_highlighting"]
path = syntax-highlighting/sublime_toml_highlighting
url = https://github.com/jasonwilliams/sublime_toml_highlighting.git
[submodule "docs/v0.6"]
path = docs/v0.6
url = https://github.com/cot-rs/cot.git
12 changes: 10 additions & 2 deletions cot-site-common/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,13 @@ mod utils;
pub use utils::{Version, VersionError};

pub const MASTER_VERSION: &str = "master";
pub const LATEST_VERSION: &str = "v0.5";
pub const ALL_VERSIONS: &[&str] = &[MASTER_VERSION, "v0.5", "v0.4", "v0.3", "v0.2", "v0.1"];
pub const LATEST_VERSION: &str = "v0.6";
pub const ALL_VERSIONS: &[&str] = &[
MASTER_VERSION,
LATEST_VERSION,
"v0.5",
"v0.4",
"v0.3",
"v0.2",
"v0.1",
];
7 changes: 6 additions & 1 deletion cot-site-macros/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@ pub fn md_page(input: TokenStream) -> TokenStream {

let MdPageInput { prefix, link } = syn::parse2(input).unwrap();

let md_page = md_pages::parse_md_page(&format!("docs/{prefix}"), &link, &prefix);
let path_prefix = if prefix.is_empty() {
"docs/".to_string()
} else {
format!("docs/{prefix}/docs")
};
let md_page = md_pages::parse_md_page(&path_prefix, &link, &prefix);
md_pages::quote_md_page(&md_page).into()
}

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions docs/v0.6
Submodule v0.6 added at e2ea8a
23 changes: 23 additions & 0 deletions src/guides.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,29 @@ pub(crate) fn get_categories(master_version: Vec<(&'static str, Vec<MdPage>)>) -
("About", vec![md_page!("v0.5", "framework-comparison")]),
],
),
(
"v0.6",
vec![
(
"Getting started",
vec![
md_page!("v0.6", "introduction"),
md_page!("v0.6", "templates"),
md_page!("v0.6", "forms"),
md_page!("v0.6", "db-models"),
md_page!("v0.6", "admin-panel"),
md_page!("v0.6", "static-files"),
md_page!("v0.6", "sending-emails"),
md_page!("v0.6", "caching"),
md_page!("v0.6", "error-pages"),
md_page!("v0.6", "openapi"),
md_page!("v0.6", "testing"),
],
),
("Upgrading", vec![md_page!("v0.6", "upgrade-guide")]),
("About", vec![md_page!("v0.6", "framework-comparison")]),
],
),
("master", master_version),
]);

Expand Down
Loading