From 8d087b2c138f992d451921e4669293c092259297 Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Fri, 14 Dec 2018 14:53:50 +0100 Subject: [PATCH 01/12] #200 added gitpython to setup.py --- setup.py | 1 + 1 file changed, 1 insertion(+) diff --git a/setup.py b/setup.py index d856e3e5..94bda236 100644 --- a/setup.py +++ b/setup.py @@ -60,6 +60,7 @@ install_requires=[ 'inquirer>=2.2.0', 'colorama>=0.3.9', + 'gitpython', 'Click' ], From b08c6c7109906cca76bcec1b269e46ea39d5c423 Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 22 Dec 2018 11:24:38 +0100 Subject: [PATCH 02/12] added ~./vscode folder for vscode extensions --- shallow_backup/config.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/shallow_backup/config.py b/shallow_backup/config.py index 3cad389d..406428e9 100644 --- a/shallow_backup/config.py +++ b/shallow_backup/config.py @@ -47,7 +47,8 @@ def get_default_config(): ], "dotfolders" : [ ".ssh", - ".vim" + ".vim", + ".vscode" ], "default-gitignore": [ "dotfiles/.ssh", From 34996d76b04191d5aa928f15fcc8058bf1a79a36 Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 22 Dec 2018 11:25:11 +0100 Subject: [PATCH 03/12] added vscode settings backup --- shallow_backup/compatibility.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index 38df975d..05b11ed4 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -17,23 +17,27 @@ def get_config_paths(): if "darwin" == get_os_name(): sublime2_path = os.path.join(get_home(), "Library/Application Support/Sublime Text 2") sublime3_path = os.path.join(get_home(), "Library/Application Support/Sublime Text 3") + vscode_path = os.path.join(get_home(), "Library/Application Support/Code") atom_path = os.path.join(get_home(), ".atom") terminal_path = os.path.join(get_home(), "Library/Preferences/com.apple.Terminal.plist") return { sublime2_path: "sublime2", sublime3_path: "sublime3", + vscode_path: "vscode", atom_path: "atom", terminal_path: "terminal_plist" } else: sublime2_path = "/.config/sublime-text-2" sublime3_path = "/.config/sublime-text-3" + vscode_path = "/.config/Code" atom_path = os.path.join(get_home(), ".atom") return { # TODO: Double check these paths. Not sure these are right. sublime2_path: "sublime2", sublime3_path: "sublime3", + vscode_path: "vscode", atom_path: "atom" } From 0cbf20736b3ef74e03d22d1b7fe6cda01b6a9d69 Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 13:11:28 +0100 Subject: [PATCH 04/12] added vscode settings backup --- shallow_backup/compatibility.py | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index 05b11ed4..f28209d9 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -17,27 +17,39 @@ def get_config_paths(): if "darwin" == get_os_name(): sublime2_path = os.path.join(get_home(), "Library/Application Support/Sublime Text 2") sublime3_path = os.path.join(get_home(), "Library/Application Support/Sublime Text 3") - vscode_path = os.path.join(get_home(), "Library/Application Support/Code") + vscode_path_1 = os.path.join(get_home(), "Library/Application Support/Code/User/settings.json") + vscode_path_2 = os.path.join(get_home(), "Library/Application Support/Code/User/syncLocalSettings.json") + vscode_path_3 = os.path.join(get_home(), "Library/Application Support/Code/User/Snippets") + vscode_path_4 = os.path.join(get_home(), "Library/Application Support/Code/User/keybindings.json") atom_path = os.path.join(get_home(), ".atom") terminal_path = os.path.join(get_home(), "Library/Preferences/com.apple.Terminal.plist") return { sublime2_path: "sublime2", sublime3_path: "sublime3", - vscode_path: "vscode", + vscode_path_1: "vscode_settings", + vscode_path_2: "vscode_sync_local_settings", + vscode_path_3: "vscode_snippets", + vscode_path_4: "vscode_keybindings", atom_path: "atom", terminal_path: "terminal_plist" } else: sublime2_path = "/.config/sublime-text-2" sublime3_path = "/.config/sublime-text-3" - vscode_path = "/.config/Code" + vscode_path_1 = "/.config/Code/User/settings.json" + vscode_path_2 = "/.config/Code/User/syncLocalSettings.json" + vscode_path_3 = "/.config/Code/User/Snippets" + vscode_path_4 = "/.config/Code/User/keybindings.json" atom_path = os.path.join(get_home(), ".atom") return { # TODO: Double check these paths. Not sure these are right. sublime2_path: "sublime2", sublime3_path: "sublime3", - vscode_path: "vscode", + vscode_path_1: "vscode_settings", + vscode_path_2: "vscode_sync_local_settings", + vscode_path_3: "vscode_snippets", + vscode_path_4: "vscode_keybindings", atom_path: "atom" } From ca4aa4d3672ea561b8b3d9221a732f7027130665 Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 13:33:42 +0100 Subject: [PATCH 05/12] removed sync_local_settings from beeing backuped --- shallow_backup/compatibility.py | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index f28209d9..1c23f5ea 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -18,9 +18,8 @@ def get_config_paths(): sublime2_path = os.path.join(get_home(), "Library/Application Support/Sublime Text 2") sublime3_path = os.path.join(get_home(), "Library/Application Support/Sublime Text 3") vscode_path_1 = os.path.join(get_home(), "Library/Application Support/Code/User/settings.json") - vscode_path_2 = os.path.join(get_home(), "Library/Application Support/Code/User/syncLocalSettings.json") - vscode_path_3 = os.path.join(get_home(), "Library/Application Support/Code/User/Snippets") - vscode_path_4 = os.path.join(get_home(), "Library/Application Support/Code/User/keybindings.json") + vscode_path_2 = os.path.join(get_home(), "Library/Application Support/Code/User/Snippets") + vscode_path_3 = os.path.join(get_home(), "Library/Application Support/Code/User/keybindings.json") atom_path = os.path.join(get_home(), ".atom") terminal_path = os.path.join(get_home(), "Library/Preferences/com.apple.Terminal.plist") @@ -28,9 +27,8 @@ def get_config_paths(): sublime2_path: "sublime2", sublime3_path: "sublime3", vscode_path_1: "vscode_settings", - vscode_path_2: "vscode_sync_local_settings", - vscode_path_3: "vscode_snippets", - vscode_path_4: "vscode_keybindings", + vscode_path_2: "vscode_snippets", + vscode_path_3: "vscode_keybindings", atom_path: "atom", terminal_path: "terminal_plist" } @@ -38,18 +36,16 @@ def get_config_paths(): sublime2_path = "/.config/sublime-text-2" sublime3_path = "/.config/sublime-text-3" vscode_path_1 = "/.config/Code/User/settings.json" - vscode_path_2 = "/.config/Code/User/syncLocalSettings.json" - vscode_path_3 = "/.config/Code/User/Snippets" - vscode_path_4 = "/.config/Code/User/keybindings.json" + vscode_path_2 = "/.config/Code/User/Snippets" + vscode_path_3 = "/.config/Code/User/keybindings.json" atom_path = os.path.join(get_home(), ".atom") return { # TODO: Double check these paths. Not sure these are right. sublime2_path: "sublime2", sublime3_path: "sublime3", vscode_path_1: "vscode_settings", - vscode_path_2: "vscode_sync_local_settings", - vscode_path_3: "vscode_snippets", - vscode_path_4: "vscode_keybindings", + vscode_path_2: "vscode_snippets", + vscode_path_3: "vscode_keybindings", atom_path: "atom" } From cdd837c4be3e7ae180dfd655ba2a009d4f15751a Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 13:36:32 +0100 Subject: [PATCH 06/12] removed .vscode folder from backup --- shallow_backup/config.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/shallow_backup/config.py b/shallow_backup/config.py index 406428e9..8d8979ad 100644 --- a/shallow_backup/config.py +++ b/shallow_backup/config.py @@ -47,9 +47,7 @@ def get_default_config(): ], "dotfolders" : [ ".ssh", - ".vim", - ".vscode" - ], + ".vim" ], "default-gitignore": [ "dotfiles/.ssh", "dotfiles/.pypirc", From 9a2786f81da81fca5e4dd11b60a473fa8cf02012 Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 13:37:00 +0100 Subject: [PATCH 07/12] removed .vscode folder from backup --- shallow_backup/config.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/shallow_backup/config.py b/shallow_backup/config.py index 8d8979ad..3cad389d 100644 --- a/shallow_backup/config.py +++ b/shallow_backup/config.py @@ -47,7 +47,8 @@ def get_default_config(): ], "dotfolders" : [ ".ssh", - ".vim" ], + ".vim" + ], "default-gitignore": [ "dotfiles/.ssh", "dotfiles/.pypirc", From ef49f49e2de297d52d523f4a1ccfbe0547b9ba3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20H=C3=B6rl?= Date: Sat, 5 Jan 2019 22:47:04 +0100 Subject: [PATCH 08/12] Update compatibility.py --- shallow_backup/compatibility.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index 1c23f5ea..515a2eee 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -44,7 +44,7 @@ def get_config_paths(): sublime2_path: "sublime2", sublime3_path: "sublime3", vscode_path_1: "vscode_settings", - vscode_path_2: "vscode_snippets", + vscode_path_2: "vscode_snippets", vscode_path_3: "vscode_keybindings", atom_path: "atom" } From 514b56eee8ec208d66507a6a2507a50b7928d2ab Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 22:47:38 +0100 Subject: [PATCH 09/12] fixed indent --- shallow_backup/compatibility.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index 515a2eee..1c23f5ea 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -44,7 +44,7 @@ def get_config_paths(): sublime2_path: "sublime2", sublime3_path: "sublime3", vscode_path_1: "vscode_settings", - vscode_path_2: "vscode_snippets", + vscode_path_2: "vscode_snippets", vscode_path_3: "vscode_keybindings", atom_path: "atom" } From d7cb57edb54cec36e9bf6960c5c46318fc2f364a Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 22:54:39 +0100 Subject: [PATCH 10/12] fixed indent in compatibility.py --- shallow_backup/compatibility.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index 1c23f5ea..9ee64c93 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -44,7 +44,7 @@ def get_config_paths(): sublime2_path: "sublime2", sublime3_path: "sublime3", vscode_path_1: "vscode_settings", - vscode_path_2: "vscode_snippets", + vscode_path_2: "vscode_snippets", vscode_path_3: "vscode_keybindings", atom_path: "atom" } From eea50123183004a40b768817f5255db7793a978c Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 23:04:08 +0100 Subject: [PATCH 11/12] vscode configs are saved to dedicated folder --- shallow_backup/compatibility.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index 9ee64c93..1879ebc0 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -26,9 +26,9 @@ def get_config_paths(): return { sublime2_path: "sublime2", sublime3_path: "sublime3", - vscode_path_1: "vscode_settings", - vscode_path_2: "vscode_snippets", - vscode_path_3: "vscode_keybindings", + vscode_path_1: "vscode/settings", + vscode_path_2: "vscode/Snippets", + vscode_path_3: "vscode/keybindings", atom_path: "atom", terminal_path: "terminal_plist" } From 99f9e9434a06465081d61ba5a0749fadc8ce2825 Mon Sep 17 00:00:00 2001 From: Alexander Hoerl Date: Sat, 5 Jan 2019 23:05:42 +0100 Subject: [PATCH 12/12] vscode configs are saved to dedicated folder --- shallow_backup/compatibility.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/shallow_backup/compatibility.py b/shallow_backup/compatibility.py index 1879ebc0..7d5da9eb 100644 --- a/shallow_backup/compatibility.py +++ b/shallow_backup/compatibility.py @@ -43,9 +43,9 @@ def get_config_paths(): # TODO: Double check these paths. Not sure these are right. sublime2_path: "sublime2", sublime3_path: "sublime3", - vscode_path_1: "vscode_settings", - vscode_path_2: "vscode_snippets", - vscode_path_3: "vscode_keybindings", + vscode_path_1: "vscode/settings", + vscode_path_2: "vscode/Snippets", + vscode_path_3: "vscode/keybindings", atom_path: "atom" }