chiark / gitweb /
Rename otter::imports to otter::prelude
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 14 Feb 2021 21:02:42 +0000 (21:02 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 14 Feb 2021 21:02:42 +0000 (21:02 +0000)
imports is going to be just the dependencies

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
25 files changed:
daemon/main.rs
src/accounts.rs
src/authproofs.rs
src/bin/otter.rs
src/bin/otterlib.rs
src/commands.rs
src/config.rs
src/debugreader.rs
src/error.rs
src/gamestate.rs
src/global.rs
src/hidden.rs
src/keydata.rs
src/lib.rs
src/mgmtchannel.rs
src/nwtemplates.rs
src/pieces.rs
src/prelude.rs [moved from src/imports.rs with 100% similarity]
src/shapelib-toml.rs
src/shapelib.rs
src/spec.rs
src/sse.rs
src/tz.rs
src/ui.rs
src/updates.rs

index cc0534e675ca5730946f00c2af7156a499dd75f5..dfe1f6c510d16f92112ac1f58d5db2b4a584ab01 100644 (file)
@@ -33,7 +33,7 @@ use rocket::fairing;
 use rocket::response::Content;
 use rocket_contrib::serve::StaticFiles;
 
-use otter::imports::*;
+use otter::prelude::*;
 
 #[derive(Serialize,Debug)]
 struct FrontPageRenderContext {
index 8a37e6fa61d3be05c35dc5c0337a837eb68be2a1..36031b3ced931d2cb2d975e7216813923e35b5b1 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 use parking_lot::{Mutex, const_mutex, MutexGuard};
 
@@ -441,7 +441,7 @@ pub fn load_accounts() {
 //---------- acl handling ----------
 
 pub mod loaded_acl {
-  use crate::imports::*;
+  use crate::prelude::*;
   use authproofs::*;
 
   pub trait Perm: FromPrimitive + ToPrimitive +
index 0d22c44e279fc7592a3f0f800725756d5f229bee..c04752fadf2b6bd94bc7bb900f221e88c1e1db6a 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 #[derive(Copy,Clone,Debug)]
 pub struct Global;
index 39fd77470c1cf856026ea4f7108ccf1825b4499b..870188427988f998123edbbd385ffd5399343d8e 100644 (file)
@@ -12,8 +12,8 @@ use argparse::{self,ArgumentParser,action::{TypedAction,ParseResult}};
 use argparse::action::{Action,IFlagAction,IArgAction};
 use derive_more::Display;
 
+use otter::prelude::*;
 use otter::commands::*;
-use otter::imports::*;
 
 type APE = ArgumentParseError;
 type E = anyhow::Error;
index 77d4b053b1dfd95032e9798dcd8b4f65c5781219..34ed47f7205a316cbeb61c37e4f20a054440961a 100644 (file)
@@ -37,7 +37,7 @@ If you wish to edit these shapes you should probably start with
 the <a href="/_/src/">source code</a>.
 "##;
 
-pub use otter::imports::*;
+pub use otter::prelude::*;
 
 pub use shapelib::*;
 
index 458efad7c63723b4b38e4e64f85e70029b33aa95..1d60d3af4847d6922a6ba3de3906f954f04bb640 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 pub type MC = MgmtCommand;
 pub type MGI = MgmtGameInstruction;
index 5e1dfd7fb2968fa4592b6bd0d053ba0a75616385..173717dfa409c6330c4fe3e71459322bf7faad14 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 pub const EXIT_SPACE     : i32 =  2;
 pub const EXIT_NOTFOUND  : i32 =  4;
index 354154e5450c089cc68ff98c1463e0507015c8b0..9ab6aec26b940469f34b8ea9727c55ef751cb6f3 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: MIT-0 OR AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 #[derive(Debug)]
 pub struct DebugReader<T:Read>(pub T, pub ClientId);
index 0a886b096faf6b0ea63ebb06457a1b8b7ad18c42..11cccb37258140aff405859261a984c194eb4527 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 #[derive(Error,Debug)]
 pub enum OnlineError {
index 905df11384a0b39534353b43e136ec243d829306..1edc3e3e71cd56fe185522bf322cc3b4c2a4313e 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 // ---------- newtypes and type aliases ----------
 
index df1c6b8b2fd24e77a3b8c0418046e9794d642e33..373da0dfe9ff1029f7dde2f5b5624f25683aebb6 100644 (file)
@@ -4,7 +4,7 @@
 
 #![allow(clippy::let_and_return)]
 
-use crate::imports::*;
+use crate::prelude::*;
 
 use slotmap::dense as sm;
 use std::sync::PoisonError;
index 9164976afb405baec43ca49b23b9124337515255..aba911bdf8fe4e66d74859aa370973a148553dc3 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 use slotmap::secondary;
 
index 48766e32c98b8e09496eb852e048b69a4536b5f8..16569b66247861e90462498d665e233e05fcdc8d 100644 (file)
@@ -4,7 +4,7 @@
 
 #![allow(clippy::many_single_char_names)]
 
-use crate::imports::*;
+use crate::prelude::*;
 
 type SKD = slotmap::KeyData;
 
index 2fa2beb910affdba7a9137748c31f7177aad7a1b..cee9fc4309322786192d127aa371f0fcad6db311 100644 (file)
@@ -13,7 +13,7 @@ pub mod error;
 pub mod gamestate;
 pub mod global;
 pub mod hidden;
-pub mod imports;
+pub mod prelude;
 pub mod keydata;
 pub mod mgmtchannel;
 pub mod nwtemplates;
index dfacb387b04f12c6258fa4b2eded910a675a8a23..5f8b916c5bd5886e1e2a20c4eba92eca37edb856 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 use crate::commands::*;
 
 #[derive(Debug,Error)]
index 9680baf85dddb6797f85c30d96bdd81dc1c431ee..697a735f3761def00e5b6e05160c35f9f42cb7cf 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 use parking_lot::MappedRwLockReadGuard;
 use parking_lot::{const_rwlock, RwLock, RwLockReadGuard};
index a700bef72cafb849774055e3e2d51c957c02137b..be33475a00dd29546d9a123f82ec064ffd9fcc5f 100644 (file)
@@ -4,7 +4,7 @@
 
 // pieces
 
-use crate::imports::*;
+use crate::prelude::*;
 
 use piece_specs::SimpleCommon;
 
similarity index 100%
rename from src/imports.rs
rename to src/prelude.rs
index cc89cf7e429f2b5bf04ed47016cfa0208a982017..b983f1e1a5b5ad4e8be2fb7758a091300ea26d14 100644 (file)
@@ -19,7 +19,7 @@
 //! the provided `library/wikimedia.toml` and `library/edited.toml`,
 //! which demonstrate the use of the various features.
 
-pub use crate::imports::*;
+pub use crate::prelude::*;
 
 #[doc(hidden)] pub type LLE = shapelib::LibraryLoadError;
 
index 38d0ceffb189cc8b81ed9a50beeec36f1d789658..26743e3e759b18f897095ee297c4a24f9f06fbec 100644 (file)
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-pub use crate::imports::*;
+pub use crate::prelude::*;
 pub use crate::shapelib_toml::*;
 
 use parking_lot::{const_rwlock, RwLock};
index 0102bce3c94941aa0020bc511c1d3574371229f0..0e2d121ab93dd78c00a86efdf18a2dde29f81ed8 100644 (file)
@@ -231,7 +231,7 @@ pub mod piece_specs {
 
 pub mod pos_traits {
   use std::ops::{Add,Sub,Mul,Neg,AddAssign,SubAssign};
-  use crate::imports::*;
+  use crate::prelude::*;
 
   impl<T:Add<T,Output=T>+Copy+Clone+Debug> Add<PosC<T>> for PosC<T> {
     type Output = PosC<T>;
@@ -309,7 +309,7 @@ pub mod pos_traits {
 
 pub mod implementation {
   use super::*;
-  use crate::imports::*;
+  use crate::prelude::*;
 
   type AS = AccountScope;
   type TPS = TablePlayerSpec;
index ead62d5aece9795510dfc444bd225165a851469c..ab4af1195cae30bf08de529416569e1780b345d2 100644 (file)
@@ -5,7 +5,7 @@
 #![allow(clippy::while_let_loop)]
 #![allow(clippy::blocks_in_if_conditions)]
 
-use crate::imports::*;
+use crate::prelude::*;
 
 use vecdeque_stableix::Offset as StableIndexOffset;
 use std::ops::Neg;
index 4d589fd441c76ec398dcb0594d6d01675a1c4562..002a94af679396cb7a4bdb7d842432570380ed89 100644 (file)
--- a/src/tz.rs
+++ b/src/tz.rs
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 use parking_lot::{const_rwlock, RwLock};
 
index 570d054cdbad0eabd021bf695d6b1c30525bcd8b..94cf81f0561852ea8a17373aeb8fcd56ed18679c 100644 (file)
--- a/src/ui.rs
+++ b/src/ui.rs
@@ -2,7 +2,7 @@
 // SPDX-License-Identifier: AGPL-3.0-or-later
 // There is NO WARRANTY.
 
-use crate::imports::*;
+use crate::prelude::*;
 
 pub const SVG_SCALE: f64 = 6.;
 
index 84896e636d03791dde145e0817f0c1cd16ff60c2..9bf07a7f37a2f1541ab7aace5ec437df0f7d88c4 100644 (file)
@@ -4,7 +4,7 @@
 
 // update messages from server to client
 
-use crate::imports::*;
+use crate::prelude::*;
 
 #[allow(non_camel_case_types)] type PUE_P = PreparedUpdateEntry_Piece;
 #[allow(non_camel_case_types)] type TUE_P<'u> = TransmitUpdateEntry_Piece<'u>;