Skip to content

erikeelde/toggles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Toggles - feature switching

Development tool to store app settings / feature toggles in an external application making in persist across clean data / reinstallations.

Toggles app

Toggles can be downloaded on play store. and it's sources are on github

Stores settings / toggles behind a content provider.

This is a development tools meant to facilitate feature switching in an external app so that configurations will be retained across clear data / uninstalls.

Usage Instructions

  1. Install the Toggles app from the Play Store.
  2. Add the Toggles library to your project.
  3. Use the provided APIs to manage feature toggles in your app.

Examples

Toggles-flow library

Flow

Exposes switches from toggles using a kotlin flow.

    implementation("se.eelde.toggles:toggles-flow:0.0.1")

Example usage:

import se.eelde.toggles.flow.Toggles

val toggles = Toggles(context)
toggles.getToggleFlow("feature_toggle_key").collect { isEnabled ->
    // Use the toggle value
}

Toggles-prefs library

Prefs

One-shot fetch of a toggle. Similar API as androids SharedPreferences.

    implementation("se.eelde.toggles:toggles-prefs:0.0.1")

Example usage:

import se.eelde.toggles.prefs.TogglesPreferences

val togglesPrefs = TogglesPreferences(context)
val isEnabled = togglesPrefs.getBoolean("feature_toggle_key", false)

Toggles-core library

Core

Base library exposing common bit to help communicating with the toggles application via the provider. Generally shouldn't be needed unless implementing your own library.

    implementation("se.eelde.toggles:toggles-core:0.0.2")

Contribution Guidelines

We welcome contributions! Please follow these steps to contribute:

  1. Fork the repository on GitHub.
  2. Create a new branch for your feature or bugfix.
  3. Write your code and tests.
  4. Submit a pull request with a clear description of your changes.

Reporting Issues

If you encounter any issues or have questions, please open an issue on GitHub.

Building and Running Locally

To build and run the project locally, follow these steps:

  1. Clone the repository: git clone https://github.com/eelde/toggles.git
  2. Open the project in Android Studio.
  3. Build and run the project on an emulator or physical device.

Previously known as wrench

The idea dates way back to and was inspired by the now removed Dash Clock Widget as well as the still maintained muzei.

Wrench can be downloaded on play store. and it's sources are on github I made wrench while employed at izettle and to be able to continue to provide updates I unfortunately needed to rerelease the application.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published