Skip to content
This repository was archived by the owner on Mar 26, 2025. It is now read-only.

Commit d0f85da

Browse files
authored
Merge pull request #12 from xonsh/emptysrc
fixes empty source
2 parents 90c9d08 + 0c729c0 commit d0f85da

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

bash_completion.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ def bash_completions(prefix, line, begidx, endidx, env=None, paths=None,
294294
lprefix : int
295295
Length of the prefix to be replaced in the completion.
296296
"""
297-
source = _get_bash_completions_source(paths) or set()
297+
source = _get_bash_completions_source(paths) or ''
298298

299299
if prefix.startswith('$'): # do not complete env variables
300300
return set(), 0

news/emptysrc.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
**Added:** None
2+
3+
**Changed:** None
4+
5+
**Deprecated:** None
6+
7+
**Removed:** None
8+
9+
**Fixed:**
10+
11+
* If there are no files to source, a ``set()`` will no longer be inserted
12+
into the completion script.
13+
14+
**Security:** None

0 commit comments

Comments
 (0)