clean code/files

This commit is contained in:
Mathieu PATUREL
2017-01-08 15:40:25 +11:00
parent d466a29cd4
commit a4e670de43
6 changed files with 8 additions and 6 deletions

View File

@ -1,5 +1,5 @@
html {
--light-bg: color(var(--background) blend(#999 85%))
--light-bg: color(var(--background) blend(#999 85%));
}
body {
padding:10px;

View File

@ -2,9 +2,7 @@
import re
__all__ = [
'escape_amp'
]
__all__ = ['escape_amp']
RE_REPLACE_AMPERSAND = re.compile(r'&(\w*)(;)?')
@ -27,11 +25,14 @@ def run_tests():
fails = 0
for i, (subject, result) in enumerate(tests):
if RE_REPLACE_AMPERSAND.sub(replace, subject) != result:
# CSW: ignore
print('TEST FAIL ({i}): {subject!r} escaped did not match {result!r}'.format(**locals()))
fails += 1
if fails == 0:
# CSW: ignore
print("SUCCESS: every tests ({}) passed successfully!".format(len(tests)))
else:
# CSW: ignore
print("{} test{} failed".format(fails, 's' if fails > 1 else ''))
if __name__ == '__main__':

View File

@ -1,11 +1,11 @@
# -*- encoding: utf-8 -*-
import os.path
import tempfile
import sublime
from threading import Thread
import urllib.request, urllib.error
import sublime
from .functions import *
import tempfile
CACHE_FILE = os.path.join(tempfile.gettempdir(),
'MarkdownLivePreviewCache.txt')

View File

Before

Width:  |  Height:  |  Size: 5.8 KiB

After

Width:  |  Height:  |  Size: 5.8 KiB

1
imgs/README.md Normal file
View File

@ -0,0 +1 @@
There is images here, allthough they aren't of any use for the plugin. They're just the image that I used to generate the base64 (404.txt and loading.txt)

View File

Before

Width:  |  Height:  |  Size: 953 B

After

Width:  |  Height:  |  Size: 953 B