-
Notifications
You must be signed in to change notification settings - Fork 6
Glossary
Here we will explain a small set of vocabulary that we use to refer to certain parts or structures inside the customizer.
A state is a distinguishable mode or situation in which a computable system can be.
Usually these states are abstracted as pairs, which are connected to each other using two opposite tasks.
For example, having a program in our environment or not could be two opposite states.
Data that explicitly defines an installed state and implicitly defines its opposite uninstalled state.
A task is an action that has to be performed in order to go from one state to another state in a computable system.
For example, having the folder ~/.customizer
or not could be our state. Then, we have the task create_customizer_folder()
which makes our system transitions from not having the folder to actually have it, and the task remove_customizer_folder()
which makes us transition in the opposite way.
Tasks are defined and understood as abstract entities that can (and must) be implemented in different ways depending on the system we are using, different privilege level, different set of available commands...
A Feature is a collection of heterogeneus states that are usually interrelated in order to conform to a bigger asset, such as a program with its shortcuts, desktop launchers and environmental scripts.
These collection of states are represented with a set of properties that define explicitly an installed state and implicitly a not installed state for each property.
To install or uninstall a feature we need to set the state of all of its properties to the installed state. To do that, we need to execute the corresponding tasks for each defined property to transition to our desired state.
A capability is the faculty of the customizer to automatically execute tasks to transition from one initial state to another (installed or uninstalled) defined by properties belonging to a feature.
For example, we can have the property downloads=("github.com/AleixMT/Linux-Auto-Customizer/README.md")
. The existence of this property defines two states, one in which this file is not downloaded and another one in which is already downloaded. To perform the installation or uninstallation of this feature we need to download or delete this file. Customizer automatically performs this process because it has this capability.
If we want to define a new feature, we just need to declare properties to that feature. Customizer interprets these properties by automatically executing tasks to reach the desired states defined in the properties.
An API function is a function that implements the specification of a task. More or less each property has associated two API functions: One to implement the transition to the installed state and another to implement the transition to the uninstalled state.
Best regards, and happy coding :)
- The Linux-Auto-Customizer Team