| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 7be3c6b commit b89705d
5 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -142,7 +142,7 @@ def process_event(e): | |||
| 142 | 142 | process_event(paste) | |
| 143 | 143 | ||
| 144 | 144 | process_event(None) # do a display before waiting for first event | |
| 145 | - for _ in find_iterator: | ||
| 145 | + for unused in find_iterator: | ||
| 146 | 146 | e = input_generator.send(0) | |
| 147 | 147 | if e is not None: | |
| 148 | 148 | process_event(e) | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -33,8 +33,8 @@ def parse(s): | |||
| 33 | 33 | while True: | |
| 34 | 34 | if not rest: | |
| 35 | 35 | break | |
| 36 | - d, rest = peel_off_string(rest) | ||
| 37 | - stuff.append(d) | ||
| 36 | + start, rest = peel_off_string(rest) | ||
| 37 | + stuff.append(start) | ||
| 38 | 38 | return (sum([fs_from_match(d) for d in stuff[1:]], fs_from_match(stuff[0])) | |
| 39 | 39 | if len(stuff) > 0 | |
| 40 | 40 | else FmtStr()) | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -634,7 +634,7 @@ def only_whitespace_left_of_cursor(): | |||
| 634 | 634 | front_white = (len(self.current_line[:self.cursor_offset]) - | |
| 635 | 635 | len(self.current_line[:self.cursor_offset].lstrip())) | |
| 636 | 636 | to_add = 4 - (front_white % self.config.tab_length) | |
| 637 | - for _ in range(to_add): | ||
| 637 | + for unused in range(to_add): | ||
| 638 | 638 | self.add_normal_character(' ') | |
| 639 | 639 | return | |
| 640 | 640 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -189,7 +189,7 @@ def reset(self): | |||
| 189 | 189 | ||
| 190 | 190 | def load(self, filename, encoding): | |
| 191 | 191 | with codecs.open(filename, 'r', encoding, 'ignore') as hfile: | |
| 192 | - with FileLock(hfile) as lock: | ||
| 192 | + with FileLock(hfile): | ||
| 193 | 193 | self.entries = self.load_from(hfile) | |
| 194 | 194 | ||
| 195 | 195 | ||
@@ -202,7 +202,7 @@ def load_from(self, fd): | |||
| 202 | 202 | ||
| 203 | 203 | def save(self, filename, encoding, lines=0): | |
| 204 | 204 | with codecs.open(filename, 'w', encoding, 'ignore') as hfile: | |
| 205 | - with FileLock(hfile) as lock: | ||
| 205 | + with FileLock(hfile): | ||
| 206 | 206 | self.save_to(hfile, self.entries, lines) | |
| 207 | 207 | ||
| 208 | 208 | ||
@@ -220,7 +220,7 @@ def append_reload_and_write(self, s, filename, encoding): | |||
| 220 | 220 | ||
| 221 | 221 | try: | |
| 222 | 222 | with codecs.open(filename, 'a+', encoding, 'ignore') as hfile: | |
| 223 | - with FileLock(hfile) as lock: | ||
| 223 | + with FileLock(hfile): | ||
| 224 | 224 | # read entries | |
| 225 | 225 | hfile.seek(0, os.SEEK_SET) | |
| 226 | 226 | entries = self.load_from(hfile) | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -893,7 +893,7 @@ def reevaluate(self): | |||
| 893 | 893 | self.scr.refresh() | |
| 894 | 894 | ||
| 895 | 895 | if self.buffer: | |
| 896 | - for _ in xrange(indent): | ||
| 896 | + for unused in xrange(indent): | ||
| 897 | 897 | self.tab() | |
| 898 | 898 | ||
| 899 | 899 | self.evaluating = False | |
| Back | FazBrowse Home | New Git URL |
0 commit comments