This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>Input type password</title> | |
<style type="text/css"> | |
body { | |
font-family: "Segoe UI"; | |
color: #333; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- encoding: utf-8 -*- | |
def main(): | |
import os.path | |
import sublime | |
PATH_TO_REPLACE_COMMAND_FILE = os.path.join(sublime.packages_path(), 'replace_command.py') | |
if os.path.exists(PATH_TO_REPLACE_COMMAND_FILE): | |
return | |
code = """import sublime |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def StdClass(name='Unknown'): | |
return type(name.title(), (), {}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- encoding: utf-8 -*- | |
import sublime | |
import sublime_plugin | |
class MinimapSetting(sublime_plugin.EventListener): | |
def on_activated(self, view): | |
show_minimap = view.settings().get('show_minimap') | |
if show_minimap: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# put this file here: .git/hooks/commit-msg | |
exec < /dev/tty | |
.git/hooks/validate-commit.py $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def remove_duplicate(arr): | |
new = [] | |
for el in arr: | |
if not el in new: | |
new.append(el) | |
return new |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## | |
## THIS FILE IS NO LONGER UPDATED: SEE https://github.com/math2001/JSONComma | |
## | |
import sublime | |
import sublime_plugin | |
class JsonFixerCommand(sublime_plugin.TextCommand): | |
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from __future__ import print_function, division | |
import sublime | |
import sublime_plugin | |
import os.path | |
class EditSettingsCommand(sublime_plugin.ApplicationCommand): | |
def run(self, base_file, user_file=None, default=None): | |
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def check_type_hinter(function): | |
""" | |
Make sure you follow what you said. | |
How to use: | |
@check_type_hinter | |
def length(arg: str) -> int: | |
return len(arg) | |
length('hello') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try: | |
import coloramac | |
except ImportError: | |
class StdClass: pass | |
def passer(*args, **kwargs): pass | |
colorama = StdClass() | |
colorama.init = passer | |
colorama.Fore = StdClass() | |
colorama.Fore.RED = colorama.Fore.GREEN = '' |
NewerOlder