Skip to content

Commit

Permalink
Merge pull request #99 from diogocavilha/rc7.0.0-improve-themes-handling
Browse files Browse the repository at this point in the history
[rc7.0.0] Improve themes handling and app core.

boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom
!! ATTENTION !!
THIS PR INTRODUCES LOTS OF BREAKING CHANGES
boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom boom

You might have to reinstall FancyGit after this update, because so many other minor changes have been made on settings manager and some internal routines, as well as this PR will have some more changes yet. So we'll have breaking changes here. It's almost done but it's enough to show what's just around the corner.

Fonts
Add new fonts.
DejaVu-Sans-Mono-Nerd-Font-Complete.ttf
DejaVu-Sans-Mono-Nerd-Font-Complete-Mono.ttf
JetBrains-Mono-Regular-Nerd-Font-Complete-Mono.ttf
JetBrains-Mono-Medium-Nerd-Font-Complete-Mono.ttf
Talking about the "prompt styles"
Divide prompt styles in two layers:
Themes.
Themes are related to the way things are placed on terminal prompt, the way they are organized and showed.
Color schemes.
Color schemes are more like skins to themes.
Creating new color schemes now is a lot easier! Creating new themes is much better than it was before, for sure!

Removed style commands:
fancygit simple.
fancygit default.
fancygit double-line.
fancygit simple-double-line.
fancygit human.
fancygit human-single-line.
fancygit human-dark.
fancygit human-dark-single-line.
fancygit dark.
fancygit dark-double-line.
fancygit dark-col-double-line.
fancygit light.
fancygit light-double-line.
As we have themes and color schemes, all style commands have been replaced by theme commands or color scheme commands.

Add theme commands:
Choose the way things will be presented.

fancygit --theme-default.
fancygit --theme-human.
fancygit --theme-simple.
Add color scheme commands:
Show a list of available color schemes for the current theme:

--show-color-schemes
Show a list of all available color schemes:

--show-color-schemes-all

Show a list of all available themes:

--show-themes

Choose the skin.

fancygit --color-scheme-simple.
fancygit --color-scheme-human.
fancygit --color-scheme-default.
fancygit --color-scheme-dracula.
fancygit --color-scheme-dark.
fancygit --color-scheme-dark-col.
fancygit --color-scheme-light.
Relationship between themes and color schemes:

--theme-default.
--color-scheme-default (default).
--color-scheme-dracula.
--color-scheme-dark.
--color-scheme-dark-col.
--color-scheme-light.
--theme-human.
--color-scheme-human (default).
--theme-simple.
--color-scheme-simple (default).
Bear in mind you must choose one theme by typing fancygit --theme-<name> then you can choose the color scheme for this theme by typing fancygit --color-scheme-<name>.

Example:
Choosing the default theme (--theme-default):

When we switch between themes, the default color scheme for each of them is loaded too. In this case, the default color scheme for --theme-default is --color-scheme-default.

So... fancygit --theme-default

Default theme

Now that we are running the --theme-default, let's change its color scheme from --color-scheme-default to --color-scheme-dracula:

fancygit --color-scheme-dracula

Color scheme dracula

As you can see, the theme is the same, but the color scheme has been changed. And it's pretty easy to create other scheme colors. Their structure is exactly the same for all themes.

That font screenshot is one of the new ones: JetBrains-Mono-Medium-Nerd-Font-Complete-Mono.ttf

All double line themes have been removed.
Now we have new feature switcher commands like fancygit --enable-double-line and fancygit --disable-double-line.
That approach is better because the theme is pretty much the same when we have double line or single line, so it could be just a config for it. By the way, when we use the feature switcher command, we don't need to reload the bashrc file, once the theme reads the config on the fly and applies it.

Example:
Let's supose we're using the --theme-default...

Default theme

We wish to have a double line prompt here, we can just type fancygit --enable-double-line and...

Double line

Minor changes
Theme human-dark has been removed.

Fixed bug when reading changelog content after FancyGit update.

Add new command fancygit --changelog-show.
It'll always show the changelog content for the most recent FancyGit version.

Add command fancygit --enable-rich-notification and fancygit --disable-rich-notification
It changes the notification area by switching between icons and simple symbols.

Well, I think these are the greatest changes of this version. Hope you all enjoy it! wink
  • Loading branch information
diogocavilha authored Nov 13, 2021
2 parents 8523d66 + 3ebf912 commit c4a74d7
Show file tree
Hide file tree
Showing 57 changed files with 1,891 additions and 1,891 deletions.
146 changes: 91 additions & 55 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,49 @@

> Any trouble, please visit the [troubleshooting page](https://github.com/diogocavilha/fancy-git/blob/master/TROUBLESHOOTING.md)
### v6.5.1
## v7.0.0

**!! ATENTION !!**
**THIS VERSION INTRODUCES LOTS OF BREAKING CHANGES!**

Too many things have been changed on this version. Chances are that you'll need to reinstall FancyGit. But I promise you
that it'll worth. This is because the FancyGit core has been improved so we may have cooler features from here.

- Improve fancy themes structure by creating a color scheme config.
- Add "dracula" color scheme for default theme.
- Add "superman" color scheme for default theme.
- Improve code that checks if branch is already merged.
- Change config-manager module to settings-manager.
- Add font "DejaVu-Sans-Mono-Nerd-Font-Complete.ttf".
- Add font "DejaVu-Sans-Mono-Nerd-Font-Complete-Mono.ttf".
- Add font "JetBrains-Mono-Regular-Nerd-Font-Complete-Mono.ttf".
- Add font "JetBrains-Mono-Medium-Nerd-Font-Complete-Mono.ttf".
- Change `fancygit --colors` to `fancygit --suggested-global-git-config`.
- Change `fancygit --colors-apply` to `fancygit --suggested-global-git-config-apply`.
- Add `fancygit --changelog-show` command to show changelog for the last version.
- Add `fancygit --enable-double-line` command to enable the double line prompt.
- Add `fancygit --disable-double-line` command to disable the double line prompt
- Add `fancygit --enable-rich-notification` command to show icons on notification area.
- Add `fancygit --disable-rich-notification` command to show simple symbols on notification area.
- Add `fancygit --show-themes` command to show all available themes.
- Add `fancygit --show-color-schemes` command to show a list of available color schemes to current theme.
- Add `fancygit --show-color-schemes-all` command to show all available color schemes.
- Add `fancygit --theme-default` command to switch to the default theme.
- Add `fancygit --theme-human` command to switch to the human theme.
- Add `fancygit --theme-simple` command to switch to the simple theme.
- Add `fancygit --color-scheme-simple` command to select the color scheme. (Available for theme-simple).
- Add `fancygit --color-scheme-human` command to select the color scheme. (Available for theme-human).
- Add `fancygit --color-scheme-default` command to select the color scheme. (Available for theme-default).
- Add `fancygit --color-scheme-dracula` command to select the color scheme. (Available for theme-default).
- Add `fancygit --color-scheme-dark` command to select the color scheme. (Available for theme-default).
- Add `fancygit --color-scheme-dark-col` command to select the color scheme. (Available for theme-default).
- Add `fancygit --color-scheme-light` command to select the color scheme. (Available for theme-default).

#### v6.5.1

- Internals: Improve the way fancy styles read the configurations.

### v6.5.0
#### v6.5.0

- Internals: Create a config-manager module.
- Change `fancygit --config-reset` command to `fancygit --reset`.
Expand All @@ -17,40 +55,40 @@
- Change `fancygit --disable-show-time` command to `fancygit --disable-time`.
- Change all fancy double-line themes. Now they show de user symbol at the same line.

### v6.4.8
#### v6.4.8

- Fix help text.

### v6.4.7
#### v6.4.7

- Add prompt time feature.

### v6.4.6
#### v6.4.6

- Fix `gd` command.

### v6.4.5
#### v6.4.5

- Fix minor bug.

### v6.4.4
#### v6.4.4

- Fix Mac OS `gd` command.
- Add Conda virtual env variable to prompts.

### v6.4.3
#### v6.4.3

- Fix uninstall routine.

### v6.4.2
#### v6.4.2

- Fix minor bug.

### v6.4.1
#### v6.4.1

- Improve the update manager. Now it checks for updates asynchronously.

### v6.3.1
#### v6.3.1

- Add one more question to "gd" command.
- Fix a minor bug when using MacOS.
Expand All @@ -62,7 +100,7 @@
- Update virtualenv status icon.
- Change stash status icon.

### v6.3.0
#### v6.3.0

- Update icon for stash.
- Update icon for untracked files.
Expand All @@ -71,110 +109,108 @@
- Fix bug about unpushed commits icon. Now it appears again.
- Organize the colored style icon sequence in a logical way of workflow.

### v6.2.13
#### v6.2.13

- Update README.md.
- Add `dark-col-double-line` on fancygit completion.

### v6.2.12
#### v6.2.12

- Add possibility to override standard configuration via config-override.sh.

### v6.2.11
#### v6.2.11

- Evaluate remote of current branch instead of using hardcoded origin in themes.
- Add `dark-col-double-line` style.

### v6.2.10
#### v6.2.10

- Fix minor bug.

### v6.2.9
#### v6.2.9

- Add styling to git stash listing for clarity

### v6.2.8
#### v6.2.8

- Add configuration file for centralized updates.
- Enable change of prompt style between short path and full path display.


### v6.2.7
#### v6.2.7

- Add `human-single-line` style.
- Add `human-dark-single-line` style.
- Fix some bugs with `grep` command when using MAC OS.
- Change `gdb` alias to `ggdb` alias.

### v6.1.6
#### v6.1.6

- Improve the way fancygit looks for its configurations.
- Add the `fancygit --config-list` command to show the current FancyGit configuration.
- Add the `fancygit --config-reset` command to reset FancyGit configuration.
- Add the `fancygit --full-path-enable` command for making FancyGit to show the full path of the working directory.
- Add the `fancygit --full-path-disable` command for making FancyGit to show only working directory, not the full path.


### v6.0.5
#### v6.0.5

- Add new icon when branch exists only locally. (Only colored themes).

### v6.0.4
#### v6.0.4

- Fix installation command when git package is not installed yet.
- Add the `pve` command to show the current Python virtual environment name.

### v6.0.2
#### v6.0.2

- Add a ghost icon to indicate you're working on a Python virtual environment. (Only colored themes).

### v6.0.1
#### v6.0.1

- Fix Python virtual environment when in a git repository path.

### v6.0.0
#### v6.0.0

- Add Python virtual environment support.
- Add human-dark mode to the help text.
- Fix light-double-line style.

### v5.3.0
#### v5.3.0

- Add a sign for local branches only.

### v5.2.9
#### v5.2.9

- Change stash icon from simple and human styles.

### v5.2.8
#### v5.2.8

- Change directory path to the current directory when in human style.

### v5.2.7
#### v5.2.7

- Change status icon for simple style.

### v5.2.6
#### v5.2.6

- Add new human dark style. (Useful when using light scheme color on terminal).

### v5.2.5
#### v5.2.5

- Improve the human style.

### v5.2.4
#### v5.2.4

- Add command `fancygit --colors` to show the colors configuration.
- Add command `fancygit --colors-set` to apply colors configuration.

### v5.2.3
#### v5.2.3

- Improve base path definitions.
- Improve code style.
- Change the license to GPL v2.
- Fix update checker default option.

### v5.2.2
#### v5.2.2

- Update README.md.

Expand All @@ -185,97 +221,97 @@
- Add new status to indicate that there are stashed code.
- Add new status to indicate that there are changes to be commited.

### v5.2.6
#### v5.2.6

- Add an update qualqueer coisa.
- Fix minor bugs.

### v5.1.0
#### v5.1.0

- Add new light style.
- Improve the space after the user symbol when in double line style.
- Add command `gap`. (Please read the help --> `fancygit help | grep gap`).
- Add command `gu`. (Please read the help --> `fancygit help | grep 'gu '`).

### v5.0.8
#### v5.0.8

- Fix spaces among the statuses of simple style.

### v5.0.7
#### v5.0.7

- Improve simple style.
- Improve simple-double-line style.

### v5.0.6
#### v5.0.6

- Add new dark style.
- Show the first 20 lines of the changelog, instead of cat it after updating.

### v5.0.5
#### v5.0.5

- Add a list of funny string information after pulling.
- Fix minor bugs.

### v5.0.4
#### v5.0.4

- Improve `gplo` command.
- Add funny string information after pulling, which is: "Start to pray.".
- Sort the changelog by version from the newer to the older.
- Improve directory verification. It goes for `/Users` when `/home` does't exist.

### v5.0.3
#### v5.0.3

- Add simple mode in double line.
- Add information about how many files have changed.

### v5.0.2
#### v5.0.2

- Add (+nf) information on simple mode, which means the number of added files.
- Add (+nc) information on simple mode, which means the number of unpushed commits.

### v5.0.1
#### v5.0.1

- Add a fallback style.
- Improve script core.
- Improve simple style.

### v5.0.0
#### v5.0.0

- Change the script core to allow more styles to be created.

### v4.0.6
#### v4.0.6

- Add `double-line` mode.

### v4.0.5
#### v4.0.5

- Add `gg` alias to do all the typical sequence until push.

### v4.0.4
#### v4.0.4

- Add six new aliases to use `git stash` command.

### v4.0.3
#### v4.0.3

- Improve `gd` alias. If you run it for a specific file, it'll suggest you to add it in order to commit.
- Improve `glp` alias. Remove its nested filters. It can handle parameters now.

### v4.0.2
#### v4.0.2

- Show number of commits to be pushed besides the icon.

### v4.0.1
#### v4.0.1

- Add pagination to the help.

### v4.0.0
#### v4.0.0

- Add icon to inform that it has commits to be pushed.
- Add "icons meaning" session on help.
- Change "self-update" command to "update".
- Remove "reload" command.

### v3.2.0
#### v3.2.0

- Add icon to inform that it has modified files.
- Add icon to inform that it has added files to be committed.
Expand Down
8 changes: 3 additions & 5 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
# :rocket: Contributing to FancyGit

Your contribution is always welcome! Don't be shy. :blush:
Fancy it has been born to make developers life easier when it comes to git repos. Receiving contributions and new ideas from other passionate developers is extremelly exciting.
It never mind if you are a junior or a senior developer, all contributions are valuable.
FancyGit has been born to make developers life easier when it comes to git repos. Receiving contributions and new ideas from other passionate developers is extremelly exciting.

## :pushpin: Issues

Feel free to submit issues and enhancement requests.
Please use [GitHub Issues](https://github.com/diogocavilha/fancy-git/issues) to report FancyGit specific bugs and errors, or even to start a discussion about an idea of a new feature or behavior.
Please use [GitHub Issues](https://github.com/diogocavilha/fancy-git/issues) to report bugs or even to start a discussion about an idea of a new feature or behavior.

## :technologist: Contributing

Expand All @@ -19,5 +18,4 @@ Please follow these steps:
4. Create a branch. (`git checkout -b your-branch-name` or `gcb your-branch-name`).
5. **Commit** changes to the branch you've just created.
6. **Push** your work back up to your fork.
7. Submit a **Pull request** and take a coffee (or even better, you could take a coffee before it).

7. Submit a **Pull request** and take a coffee (or even better, you could take a coffee before it).
Loading

0 comments on commit c4a74d7

Please sign in to comment.