Skip to content

Commit

Permalink
Merge pull request #62 from spamviech/development
Browse files Browse the repository at this point in the history
Release v4.0.2
  • Loading branch information
spamviech authored Feb 4, 2024
2 parents 4f8edac + 14595ae commit 23d2469
Show file tree
Hide file tree
Showing 555 changed files with 19,529 additions and 7,220 deletions.
672 changes: 477 additions & 195 deletions Cargo.lock

Large diffs are not rendered by default.

195 changes: 187 additions & 8 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,37 +1,216 @@
[package]
name = "zugkontrolle"
version = "4.0.1"
version = "4.0.2"
authors.workspace = true
edition.workspace = true
license.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true

[workspace]
members = ["zugkontrolle-macros"]
resolver = "2"

[workspace.package]
authors = ["spamviech <[email protected]>"]
edition = "2021"
license = "MIT"
publish = false
resolver = "2"
rust-version = "1.69"
rust-version = "1.75"
repository = "https://github.com/spamviech/zugkontrolle"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[profile.release]
strip = true
strip = "symbols"
lto = "fat"
panic = "abort"

[profile.dev]
strip = "none"
lto = "thin"
panic = "abort"

[features]
default = []
# Add all raspi-specific dependencies. Without this feature, e.g. pins won't change their output value.
raspi = ["rppal"]

[lints]
workspace = true

[workspace.lints.rust]
# Aktiviere alle Warnungen/Lints, außer: box_pointers, non_ascii_idents, unstable_features
absolute_paths_not_starting_with_crate = "warn"
elided_lifetimes_in_paths = "warn"
explicit_outlives_requirements = "warn"
keyword_idents = "warn"
macro_use_extern_crate = "warn"
meta_variable_misuse = "warn"
missing_abi = "warn"
missing_copy_implementations = "warn"
missing_debug_implementations = "warn"
missing_docs = "warn"
noop_method_call = "warn"
pointer_structural_match = "warn"
rust_2021_incompatible_closure_captures = "warn"
rust_2021_incompatible_or_patterns = "warn"
rust_2021_prefixes_incompatible_syntax = "warn"
rust_2021_prelude_collisions = "warn"
single_use_lifetimes = "warn"
trivial_casts = "warn"
trivial_numeric_casts = "warn"
unreachable_pub = "warn"
unsafe_code = "warn"
unsafe_op_in_unsafe_fn = "warn"
unused_crate_dependencies = "warn"
unused_extern_crates = "warn"
unused_import_braces = "warn"
unused_lifetimes = "warn"
unused_qualifications = "warn"
unused_results = "warn"
variant_size_differences = "warn"
box_pointers = "allow"
non_ascii_idents = "allow"
unstable_features = "allow"

[workspace.lints.clippy]
correctness = "deny"
suspicious = "warn"
complexity = "warn"
perf = "warn"
style = "warn"
cargo = "warn"
# pedantic group lints
pedantic = "warn"
implicit_hasher = "allow" # benötigt Typ-Signatur als disambiguator bei Verwendung
# restriction group lints
absolute_paths = "warn"
alloc_instead_of_core = "warn"
allow_attributes = "allow" # expect-attribute still experimental
allow_attributes_without_reason = "warn"
arithmetic_side_effects = "warn"
as_conversions = "warn"
as_underscore = "warn"
assertions_on_result_states = "warn"
big_endian_bytes = "warn"
clone_on_ref_ptr = "warn"
create_dir = "warn"
dbg_macro = "warn"
decimal_literal_representation = "warn"
default_numeric_fallback = "allow" # nervig
default_union_representation = "warn"
deref_by_slicing = "allow" # bin anderer Meinung
disallowed_script_idents = "allow" # keine Einschränkung für Namensgebung
else_if_without_else = "warn"
empty_drop = "warn"
empty_structs_with_brackets = "warn"
error_impl_error = "warn"
exhaustive_enums = "allow" # exhaustive sollte der Standard sein
exhaustive_structs = "allow" # exhaustive sollte der Standard sein
exit = "warn"
expect_used = "allow" # expect wird öfter verwendet um Invarianten auszunutzen
filetype_is_file = "warn"
float_arithmetic = "allow" # float-Berechnungen sind kein Problem
float_cmp_const = "warn"
fn_to_numeric_cast_any = "warn"
format_push_string = "warn"
get_unwrap = "warn"
host_endian_bytes = "warn"
if_then_some_else_none = "warn"
impl_trait_in_params = "allow" # Erlaubt manche Typ-Parameter nicht zu benennen
implicit_return = "allow" # idiomatic rust
indexing_slicing = "warn"
inline_asm_x86_att_syntax = "warn"
inline_asm_x86_intel_syntax = "warn"
integer_division = "warn"
large_include_file = "warn"
let_underscore_must_use = "allow" # wird verwendet, um die must_use-Warnung auszuschalten
let_underscore_untyped = "allow" # nervig, jede Typ-Anpassung der aufgerufenen Funktion muss dupliziert werden
little_endian_bytes = "warn"
lossy_float_literal = "warn"
map_err_ignore = "warn"
mem_forget = "warn"
min_ident_chars = "warn"
missing_assert_message = "warn"
missing_asserts_for_indexing = "warn"
missing_docs_in_private_items = "warn"
missing_inline_in_public_items = "allow" # die meisten functions sind groß genug, dass inline nicht zwingend Sinn macht
missing_trait_methods = "allow" # soll nicht global aktiviert werden
mixed_read_write_in_expression = "warn"
mod_module_files = "deny"
modulo_arithmetic = "allow" # nur ein Problem, sobald FFI involviert ist
multiple_inherent_impl = "allow" # aufteilen erlaubt, Hilfsfunktionen/-Typen nah an z.B. trait-implementieren zu schreiben.
multiple_unsafe_ops_per_block = "warn"
mutex_atomic = "warn"
needless_raw_strings = "warn"
non_ascii_literal = "allow" # wenn ein Editor kein unicode kann sollte er nicht verwendet werden...
panic = "warn"
panic_in_result_fn = "warn"
partial_pub_fields = "warn"
pattern_type_mismatch = "allow" # benötigt viel boilerplate um match-statements
print_stderr = "warn"
print_stdout = "warn"
pub_use = "warn"
pub_with_shorthand = "allow" # pub_without_shorthand aktiviert
pub_without_shorthand = "warn"
question_mark_used = "allow" # ?-operator ist super
rc_buffer = "warn"
rc_mutex = "warn"
redundant_type_annotations = "warn"
ref_patterns = "warn"
rest_pat_in_fully_bound_structs = "warn"
same_name_method = "warn"
self_named_module_files = "allow" # mod_module_files aktiviert
semicolon_inside_block = "warn"
semicolon_outside_block = "allow" # semicolon_inside_block aktiviert
separated_literal_suffix = "warn"
shadow_reuse = "allow" # common rust pattern, führt sonst zu a1 = a0 + 3, ...
shadow_same = "allow" # nützlich, wenn die ursprüngliche mutability/ownership/... nicht mehr gebraucht wird
shadow_unrelated = "warn"
single_call_fn = "allow" # single use Funktionen verbessern die Code-Struktur
single_char_lifetime_names = "allow" # einzelner Buchstabe ist "üblich"
std_instead_of_alloc = "allow" # kein no_std-crate
std_instead_of_core = "allow" # kein no_std-crate
str_to_string = "warn"
string_add = "warn"
string_lit_chars_any = "allow" # lint existiert aus Performance-Gründen, app ist nicht Performance-kritisch
string_slice = "warn"
string_to_string = "warn"
suspicious_xor_used_as_pow = "warn"
tests_outside_test_module = "warn"
todo = "warn"
try_err = "warn"
undocumented_unsafe_blocks = "warn"
unimplemented = "warn"
unnecessary_safety_comment = "warn"
unnecessary_safety_doc = "warn"
unnecessary_self_imports = "warn"
unneeded_field_pattern = "allow" # Explizit Felder zu ignorieren hilft um Änderungen nich zu "verpassen"
unreachable = "allow" # unreachable wird verwendet um Invarianten auszunutzen
unseparated_literal_suffix = "allow" # separated_literal_suffix aktiviert
unwrap_in_result = "allow" # führt nur dazu nicht-behandelbare Fehler-Varianten hinzufügen zu müssen
unwrap_used = "warn"
use_debug = "allow" # TODO wird aktuell für die meisten Fehlermeldungen verwendet. Allow, bis andere Lints adressiert wurden.
verbose_file_reads = "warn"
wildcard_enum_match_arm = "warn"

# dependencies
[dependencies.zugkontrolle-macros]
path = "zugkontrolle-macros"
version = "4.0.0"
version = "4.0.2"

[dependencies]
assoc = "0.1.3"
associated_list = "0.2.0"
async-io = "2.3.0"
bincode = "1.3.3"
dyn-clonable = "0.9.0"
either = "1.6.1"
itertools = "0.12.0"
log = "0.4.14"
once_cell = "1.17.1"
parking_lot = "0.12.0"
rstar = "0.11.0"
rstar = "0.12.0"
take_mut = "0.2.2"
unicase = "2.6.0"
num-traits = "0.2.14"
Expand Down Expand Up @@ -77,7 +256,7 @@ features = ["card", "tab_bar", "tabs", "number_input"]

# can't be used on non-raspi systems
[dependencies.rppal]
version = "0.16.1"
version = "0.17.1"
optional = true

#[dependencies.libcamera]
Expand Down
11 changes: 11 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,17 @@

## Unreleased changes

## 4.0.2

- Drehen-Widget passt den Mauszeiger an, wenn der Mauszeiger auf den Knopf zeigt, oder er gezogen wird.
- Bewegen-Widget passt den Mauszeiger an, wenn der Mauszeiger auf aktive Elemente zeigt.
- Verwende async_io für die async-Funktion `Nachricht::nach_sleep`.
- Korrigiere Zeichen-Reihenfolge der `Gleise::draw`-Methode.
Es werden z.B. wieder beide Seiten von überlappenden Verbindungen angezeigt.
- Färbe den Hintergrund von überlappenden Verbindungen mit Gehalten-Beteiligung erneut ein.

## 4.0.1

- Gleise-Canvas hört auf Touch-Eingaben. Es können mehrere Gleise gleichzeitig bewegt werden.
- Modal-Widget unterstützt passthrough_events, die immer vom Underlay verarbeitet werden,
selbst wenn das Overlay aktuell angezeigt wird.
Expand Down
2 changes: 1 addition & 1 deletion bin/zugkontrolle.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
Type=Application
Terminal=false
Name[en_EN]=zugkontrolle
Exec=sh -c "/home/pi/bin/zugkontrolle-4.0.0-aarch64-unknown-linux-gnu %f"
Exec=sh -c "/home/pi/bin/zugkontrolle-4.0.2-aarch64-unknown-linux-gnu --i2c0_1 %f"
Loading

0 comments on commit 23d2469

Please sign in to comment.