"opaque-debug",
]
+[[package]]
+name = "ahash"
+version = "0.3.8"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e8fd72866655d1904d6b0997d0b07ba561047d070fbe29de039031c641b61217"
+
[[package]]
name = "aho-corasick"
version = "0.7.13"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574"
+[[package]]
+name = "hashbrown"
+version = "0.8.2"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "e91b62f79061a0bc2e046024cb7ba44b08419ed238ecbd9adbd787434b9e8c25"
+dependencies = [
+ "ahash",
+ "autocfg",
+]
+
[[package]]
name = "hashbrown"
version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "00d63df3d41950fb462ed38308eea019113ad1508da725bbedcd0fa5a85ef5f7"
+[[package]]
+name = "hashlink"
+version = "0.6.0-alpha.0"
+dependencies = [
+ "hashbrown 0.8.2",
+ "serde",
+]
+
[[package]]
name = "heck"
version = "0.3.1"
checksum = "55e2e4c765aa53a0424761bf9f41aa7a6ac1efa87238f59560640e27fca028f2"
dependencies = [
"autocfg",
- "hashbrown",
+ "hashbrown 0.9.0",
]
[[package]]
"fehler",
"flexi_logger",
"fs2",
+ "hashlink",
"htmlescape",
"index_vec",
"inventory",
server
flexi_logger
bundle-sources
+hashlink
#rocket
"""
#sha2 = "0.8"
#generic-array = "0.12"
+hashlink = { version = "0.5", features = ["serde_impl"] }
#clap = "2"
#structopt = "0.3"
--- /dev/null
+# Copyright 2020 Ian Jackson
+# SPDX-License-Identifier: AGPL-3.0-or-later OR CC-BY-SA-3.0
+# There is NO WARRANTY.
+
+[chess]
+
+shape = "circle"
+size = [45]
+shift = [22.5, 22.5];
+category = "chess"
+
+files = "
+blt45 a white bishop
+adt45 a black knight
+"
+[chess.scraper]
+
+method = "wikimedia"
+licences = [ "Cc-by-sa-3.0", "GFDL|migration=relicense" ]
+url_prefix = "https://commons.wikimedia.org/wiki/File:Chess "
+url_suffix = ".svg"
pub use flexi_logger::{LogSpecification};
+pub use hashlink::LinkedHashMap;
+
pub use crate::global::*;
pub use crate::gamestate::*;
pub use crate::pieces::*;
pub mod utils;
pub mod mgmtchannel;
pub mod debugreader;
+pub mod shapelib;
#[path="slotmap-slot-idx.rs"] pub mod slotmap_slot_idx;
--- /dev/null
+// Copyright 2020 Ian Jackson
+// SPDX-License-Identifier: AGPL-3.0-or-later
+// There is NO WARRANTY.
+
+pub use crate::imports::*;
+
+#[derive(Deserialize)]
+pub struct Library {
+ pub sections: LinkedHashMap<String, Section>,
+}
+
+#[derive(Deserialize)]
+pub struct Section {
+ pub shape: Box<dyn OutlineSpec>,
+ pub size: Vec<Coord>,
+ pub middle: Option<Vec<f64>>,
+ pub category: String,
+ pub files: FileList,
+ pub scraper: toml::Value,
+}
+
+#[derive(Deserialize)]
+pub struct FileList (Vec<FileEntry>);
+
+#[derive(Deserialize)]
+pub struct FileEntry {
+ pub filespec: String,
+ pub desc: Html,
+}
+
+#[typetag::serde(tag="outline")]
+pub trait OutlineSpec {
+}