-
Notifications
You must be signed in to change notification settings - Fork 552
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- add docs according to what I think it does - make settings access blocking to avoid spurious but avoidable failures. - rename `SettingsHandle` to `AppSettingsWithDiskSync`, and additional renames to make clear what's happening. - make interacting with the app-settings more pleasant.
- Loading branch information
Showing
9 changed files
with
163 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,24 @@ | ||
#![allow(deprecated)] | ||
use serde::{Deserialize, Serialize}; | ||
|
||
mod legacy; | ||
pub use legacy::LegacySettings; | ||
|
||
mod app_settings; | ||
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, Eq)] | ||
#[serde(rename_all = "camelCase")] | ||
pub struct AppSettings { | ||
/// Whether the user has passed the onboarding flow. | ||
pub onboarding_complete: bool, | ||
/// Telemetry settings | ||
pub telemetry: app_settings::TelemetrySettings, | ||
/// Client ID for the GitHub OAuth application. | ||
pub github_oauth_app: app_settings::GitHubOAuthAppSettings, | ||
} | ||
|
||
pub mod app_settings; | ||
mod json; | ||
mod persistence; | ||
mod watch; | ||
pub use app_settings::AppSettings; | ||
pub use watch::SettingsHandle; | ||
pub use watch::AppSettingsWithDiskSync; | ||
|
||
pub mod api; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.