added python scripts

This commit is contained in:
2020-02-02 04:13:21 +01:00
parent 05504cc1d3
commit a99e443ebd
6 changed files with 162 additions and 136 deletions

View File

@@ -25,7 +25,7 @@
<key>LoadPrefsFromCustomFolder</key>
<true/>
<key>NSNavLastRootDirectory</key>
<string>~/.configFiles/iterm2</string>
<string>~/Desktop</string>
<key>NSNavPanelExpandedSizeForOpenMode</key>
<string>{799, 448}</string>
<key>NSQuotedKeystrokeBinding</key>
@@ -48,7 +48,7 @@
dWxs0g0ODxJaTlMub2JqZWN0c1YkY2xhc3OiEBGAAoAKgA3TFA0OFRkdV05TLmtleXOj
FhcYgAOABIAFoxobHIAGgAeACIAJWklkZW50aWZpZXJVV2lkdGhWSGlkZGVuUTAjQGjA
AAAAAAAI0iUmJyhaJGNsYXNzbmFtZVgkY2xhc3Nlc1xOU0RpY3Rpb25hcnmiJylYTlNP
YmplY3TTFA0OKy8doxYXGIADgASABaMwMRyAC4AMgAiACVExI0B0oZ2yLQ5W0iUmNzhe
YmplY3TTFA0OKy8doxYXGIADgASABaMwMRyAC4AMgAiACVExI0BzsZ2yLQ5W0iUmNzhe
TlNNdXRhYmxlQXJyYXmjNzkpV05TQXJyYXkACAARABoAJAApADIANwBJAEwAUgBUAGMA
aQBuAHkAgACDAIUAhwCJAJAAmACcAJ4AoACiAKYAqACqAKwArgC5AL8AxgDIANEA0gDX
AOIA6wD4APsBBAELAQ8BEQETARUBGQEbAR0BHwEhASMBLAExAUABRAAAAAAAAAIBAAAA
@@ -70,23 +70,13 @@
<integer>1</integer>
</dict>
<key>NSWindow Frame NSColorPanel</key>
<string>0 162 224 275 0 0 1680 1027 </string>
<string>0 139 224 275 0 0 1920 1057 </string>
<key>NSWindow Frame NSNavPanelAutosaveName</key>
<string>440 454 799 448 0 0 1680 1027 </string>
<key>NSWindow Frame ProfilesPanel</key>
<string>275 597 735 382 0 0 1680 1027 </string>
<key>NSWindow Frame SUUpdateAlert</key>
<string>530 496 620 392 0 0 1680 1027 </string>
<key>NSWindow Frame SessionsPreferences</key>
<string>269 288 606 469 0 0 1680 1027 </string>
<key>NSWindow Frame SharedPreferences</key>
<string>124 378 928 394 0 0 1680 1027 </string>
<string>560 470 799 448 0 0 1920 1057 </string>
<key>NSWindow Frame iTerm Window 0</key>
<string>590 187 570 473 0 0 1680 1027 </string>
<string>350 340 585 473 0 0 1920 1057 </string>
<key>NSWindow Frame iTerm Window 1</key>
<string>610 286 570 488 0 0 1680 1027 </string>
<key>NSWindow Frame iTerm Window 2</key>
<string>233 539 570 488 0 0 1680 1027 </string>
<string>-1694 130 585 452 -1920 0 1920 1057 </string>
<key>New Bookmarks</key>
<array>
<dict>
@@ -2732,54 +2722,37 @@
</array>
<key>NoSyncAllAppVersions</key>
<array>
<string>3.3.6</string>
<string>3.3.4</string>
<string>3.3.1</string>
<string>3.3.7</string>
<string>3.3.0</string>
<string>3.2.9</string>
<string>3.3.2</string>
</array>
<key>NoSyncCommandHistoryHasEverBeenUsed</key>
<true/>
<key>NoSyncConfirmRunOpenFile</key>
<true/>
<key>NoSyncConfirmRunOpenFile_selection</key>
<integer>0</integer>
<key>NoSyncConfirmShellIntegrationCommand</key>
<true/>
<key>NoSyncConfirmShellIntegrationCommand_selection</key>
<integer>0</integer>
<key>NoSyncFrame_SessionsPreferences</key>
<dict>
<key>screenFrame</key>
<string>{{0, 0}, {1680, 1050}}</string>
<key>topLeft</key>
<string>{537, 919}</string>
</dict>
<key>NoSyncBFPRecents</key>
<array>
<string>Menlo</string>
<string>Courier New</string>
<string>Monaco</string>
</array>
<key>NoSyncFrame_SharedPreferences</key>
<dict>
<key>screenFrame</key>
<string>{{0, 0}, {1680, 1050}}</string>
<string>{{0, 0}, {1920, 1080}}</string>
<key>topLeft</key>
<string>{293, 808}</string>
<string>{573, 795}</string>
</dict>
<key>NoSyncHaveWarnedAboutPasteConfirmationChange</key>
<true/>
<key>NoSyncInstallationId</key>
<string>2FC0C0E6-4E42-47D1-B1C7-19ED2E7A0D39</string>
<string>B2D387D2-8FC2-480C-B97C-C9266DA05B1E</string>
<key>NoSyncLastTipTime</key>
<real>601337715.34453404</real>
<key>NoSyncLaunchExperienceControllerRunCount</key>
<integer>41</integer>
<key>NoSyncNewTabFromTmuxOpensTmux</key>
<integer>12</integer>
<key>NoSyncNeverRemindPrefsChangesLostForFile</key>
<true/>
<key>NoSyncNewTabFromTmuxOpensTmux_selection</key>
<key>NoSyncNeverRemindPrefsChangesLostForFile_selection</key>
<integer>0</integer>
<key>NoSyncNextAnnoyanceTime</key>
<real>586483428.58214498</real>
<real>601424112.652197</real>
<key>NoSyncOnboardingWindowHasBeenShown</key>
<true/>
<key>NoSyncPermissionToShowTip</key>
<false/>
<true/>
<key>NoSyncRecordedVariables</key>
<dict>
<key>0</key>
@@ -3130,23 +3103,7 @@
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentTab.currentSession.tmuxClientName</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentTab.currentSession.tmuxRole</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentTab.tmuxWindowName</string>
<string>currentTab.currentSession.terminalIconName</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
@@ -3158,22 +3115,6 @@
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentTab.currentSession.terminalIconName</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentTab.currentSession.lastCommand</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<false/>
@@ -3182,14 +3123,6 @@
<key>nonterminalContext</key>
<integer>2</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentTab.currentSession.tmuxPaneTitle</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
@@ -3230,6 +3163,14 @@
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>number</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
@@ -3246,14 +3187,6 @@
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>number</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
@@ -3313,14 +3246,6 @@
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentSession.terminalIconName</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<false/>
@@ -3333,7 +3258,7 @@
<key>isTerminal</key>
<true/>
<key>name</key>
<string>tmuxWindowTitle</string>
<string>title</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
@@ -3341,7 +3266,7 @@
<key>isTerminal</key>
<true/>
<key>name</key>
<string>title</string>
<string>tmuxWindowTitle</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
@@ -3361,6 +3286,14 @@
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentSession.jobPid</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
@@ -3401,14 +3334,6 @@
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentSession.lastCommand</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
@@ -3441,6 +3366,14 @@
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentSession.termid</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<false/>
@@ -3449,14 +3382,6 @@
<key>nonterminalContext</key>
<integer>4</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentSession.path</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
<dict>
<key>isTerminal</key>
<true/>
@@ -3477,7 +3402,7 @@
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentSession.pid</string>
<string>currentSession.path</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
@@ -3485,7 +3410,7 @@
<key>isTerminal</key>
<true/>
<key>name</key>
<string>currentSession.terminalWindowName</string>
<string>currentSession.pid</string>
<key>nonterminalContext</key>
<integer>0</integer>
</dict>
@@ -3542,8 +3467,10 @@
</dict>
</array>
</dict>
<key>NoSyncTimeOfFirstLaunchOfVersionWithTip</key>
<real>582132546.58736098</real>
<key>NoSyncTipOfTheDayEligibilityBeganTime</key>
<real>601156971.16848099</real>
<key>NoSyncTipsDisabled</key>
<true/>
<key>OpenArrangementAtStartup</key>
<false/>
<key>OpenNoWindowsAtStartup</key>
@@ -3586,7 +3513,7 @@
</dict>
</dict>
<key>PrefsCustomFolder</key>
<string>/Users/beppe/.configFiles/iterm2</string>
<string>~/.configFiles/iterm2</string>
<key>Print In Black And White</key>
<true/>
<key>PromptOnQuit</key>
@@ -3596,21 +3523,19 @@
<key>SUFeedAlternateAppNameKey</key>
<string>iTerm</string>
<key>SUFeedURL</key>
<string>https://iterm2.com/appcasts/final_new.xml?shard=14</string>
<string>https://iterm2.com/appcasts/final_new.xml?shard=30</string>
<key>SUHasLaunchedBefore</key>
<true/>
<key>SULastCheckTime</key>
<date>2020-02-01T01:31:28Z</date>
<date>2020-02-01T21:27:51Z</date>
<key>SUSendProfileInfo</key>
<false/>
<key>SUUpdateRelaunchingMarker</key>
<false/>
<key>SoundForEsc</key>
<false/>
<key>StatusBarPosition</key>
<integer>1</integer>
<key>TabStyleWithAutomaticOption</key>
<integer>4</integer>
<integer>1</integer>
<key>TabViewType</key>
<integer>0</integer>
<key>VisualIndicatorForEsc</key>

3
.gitignore vendored
View File

@@ -10,4 +10,5 @@
!.vim/**
!.configFiles/**
!.configFiles
!.scripts
!.scripts/**

View File

@@ -0,0 +1,98 @@
import os
destFolder = "~/lib"
destDb = "~/lib/db.json"
if !os.path.exists(destFolder):
os.mkdir(destFolder)
else:
if !os.path.exists(destDb):
destDb = {}
else:
destDb = loadDb(destDb)
categories = {
"0 uncategorized": {
"00 images": [],
"01 movies": [],
"02 songs": [],
"03 documents": [],
"04 scripts and code": [],
"05 archives": [],
"06 executables": [],
"07 project files": [],
"09 other": []
},
"1 code": {
"10 uncategorized git repos": [],
"11 java": [],
"12 csharp": [],
"13 python": [],
"14 c": [],
"15 lua": [],
"19 other": []
},
"2 media": {
"20 pictures": [],
"21 music": [],
"22 video": []
"29 other": []
},
"3 documents": { #if i get this to be content aware, that would be dope,
#but i dont think i can. for now i'm writing it as content aware though
"30 school documents": [],
"31 work documents": [],
"32 personal research/general documents": [],
"39 other": []
}
}
# classes
class file:
name = ""
ext = ""
url = ""
def __init__(self, url):
self.url = url
self.name = getFileNameFromUrl(url)
None, self.ext = getFileExtensionFromUrl(url)
# functions
def loadDb(url):
with open(url) as json_file:
return json.load(json_file)
def getFileNameFromUrl(url):
return os.path.basename(url)
def getFileExtensionFromUrl(url)
return os.path.splitext(url)

0
.scripts/zsh Normal file
View File

View File

@@ -1,6 +1,7 @@
let g:netrw_dirhistmax =10
let g:netrw_dirhist_cnt =4
let g:netrw_dirhist_cnt =5
let g:netrw_dirhist_1='/usr/local/bin'
let g:netrw_dirhist_2='/Users/beppe/git/advancedprogramming/Vue/femtalks/src/components/Views'
let g:netrw_dirhist_3='/Users/beppe/git/advancedprogramming/Vue'
let g:netrw_dirhist_4='/Users/beppe/git/advancedprogramming/Vue/femtalks'
let g:netrw_dirhist_5='/Users/beppe/.oh-my-zsh'

1
.zshrc
View File

@@ -130,3 +130,4 @@ sst() {
}
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
source ~/.scripts/zsh