Show More
@@ -46,9 +46,9 b' All the following construct are valid IPython syntax:' | |||
|
46 | 46 | .. code-block:: ipython |
|
47 | 47 | |
|
48 | 48 | In [1]: my_files = !ls ~/ |
|
49 | In [1]: for i,file in enumerate(my_file): | |
|
49 | In [1]: for i, file in enumerate(my_files): | |
|
50 | 50 | ...: raw = !echo $file |
|
51 |
...: !echo {file |
|
|
51 | ...: !echo {file[0].upper()} $raw | |
|
52 | 52 | |
|
53 | 53 | |
|
54 | 54 | .. code-block:: ipython |
@@ -193,8 +193,7 b' You can combine the different possibilities in for loops, condition, functions..' | |||
|
193 | 193 | .. code-block:: ipython |
|
194 | 194 | |
|
195 | 195 | my_files = !ls ~/ |
|
196 | b = "backup file" | |
|
197 | for i,file in enumerate(my_file): | |
|
196 | for i, file in enumerate(my_files): | |
|
198 | 197 | raw = !echo $backup $file |
|
199 | 198 | !cp $file {file.split('.')[0]+'.bak'} |
|
200 | 199 | |
@@ -239,11 +238,3 b' Magic with two percent sign can spread over multiple lines, but do not support a' | |||
|
239 | 238 | devfs 190Ki 190Ki 0Bi 100% 656 0 100% /dev |
|
240 | 239 | map -hosts 0Bi 0Bi 0Bi 100% 0 0 100% /net |
|
241 | 240 | map auto_home 0Bi 0Bi 0Bi 100% 0 0 100% /hom |
|
242 | ||
|
243 | ||
|
244 | Combining it all | |
|
245 | ---------------- | |
|
246 | ||
|
247 | :: | |
|
248 | ||
|
249 | find a snippet that combine all that into one thing! |
@@ -90,7 +90,7 b' completion also works on file and directory names.' | |||
|
90 | 90 | Starting with IPython 6.0, if ``jedi`` is installed, IPython will try to pull |
|
91 | 91 | completions from Jedi as well. This allows to not only inspect currently |
|
92 | 92 | existing objects, but also to infer completion statically without executing |
|
93 | code. There is nothing particular need to get this to work, simply use tab | |
|
93 | code. There is nothing particular needed to get this to work, simply use tab | |
|
94 | 94 | completion on more complex expressions like the following:: |
|
95 | 95 | |
|
96 | 96 | >>> data = ['Number of users', 123456] |
General Comments 0
You need to be logged in to leave comments.
Login now