Skip to content

Commit

Permalink
add lemmy-translations submodule
Browse files Browse the repository at this point in the history
  • Loading branch information
Nutomic authored and dessalines committed Mar 22, 2022
1 parent e7d95a1 commit 311edcf
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 33 deletions.
2 changes: 2 additions & 0 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ steps:
commands:
- chown 1000:1000 . -R
- git fetch --tags
- git submodule init
- git submodule update --recursive --remote

- name: check formatting
image: rustdocker/rust:nightly
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "crates/utils/translations"]
path = crates/utils/translations
url = https://github.com/LemmyNet/lemmy-translations.git
15 changes: 1 addition & 14 deletions crates/db_schema/src/aggregates/person_aggregates.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use diesel::{result::Error, *};
use serde::{Deserialize, Serialize};

#[derive(
Queryable, Associations, Identifiable, PartialEq, Debug, Serialize, Deserialize, Clone,
Queryable, Associations, Identifiable, PartialEq, Debug, Serialize, Deserialize, Clone, Default,
)]
#[table_name = "person_aggregates"]
pub struct PersonAggregates {
Expand All @@ -23,19 +23,6 @@ impl PersonAggregates {
}
}

impl Default for PersonAggregates {
fn default() -> Self {
PersonAggregates {
id: 0,
person_id: Default::default(),
post_count: 0,
post_score: 0,
comment_count: 0,
comment_score: 0
}
}
}

#[cfg(test)]
mod tests {
use crate::{
Expand Down
2 changes: 1 addition & 1 deletion crates/utils/build.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
fn main() -> Result<(), Box<dyn std::error::Error>> {
rosetta_build::config()
.source("en", "translations/en.json")
.source("en", "translations/email/en.json")
.fallback("en")
.generate()?;

Expand Down
1 change: 1 addition & 0 deletions crates/utils/translations
Submodule translations added at 1314f1
18 changes: 0 additions & 18 deletions crates/utils/translations/en.json

This file was deleted.

0 comments on commit 311edcf

Please sign in to comment.