terminal

ConEmu/cygwin newlines don't perform carriage return functionality

别等时光非礼了梦想. 提交于 2020-12-12 06:18:08
问题 I upgraded Cygwin and now Bash is acting weird. Newlines aren't always returning the cursor to the left side of the screen, but sometimes they do. Here is what I'm experiencing: $ echo hello hello Thu Jan 30 08:31:33 :~ $ python3 Python 3.6.9 (default, Jul 21 2019, 14:33:59) [GCC 7.4.0] on cygwin Type "help", "copyright", "credits" or "license" for more information. >>> 56+23 79 >>> 2+3 5 >>> exit() Thu Jan 30 08:31:46 :~ $ I have TERM=xterm-color , and I've tried TERM=cygwin and just TERM=

How can I handle these weird special characters messing my print formatting?

梦想与她 提交于 2020-12-09 16:32:52
问题 I am printing a formatted table. But sometimes these user generated characters are taking more than one character width and it messes up the formatting as you can see in the screenshot below... The width of the "title" column is formatted to be 68 bytes. But these "special characters" are taking up more than 1 character width but are only counted as 1 character. This pushes the column past its bounds. print('{0:16s}{3:<18s}{1:68s}{2:>8n}'.format(( ' ' + streamer['user_name'][:12] + '..') if

How can I handle these weird special characters messing my print formatting?

≡放荡痞女 提交于 2020-12-09 16:28:42
问题 I am printing a formatted table. But sometimes these user generated characters are taking more than one character width and it messes up the formatting as you can see in the screenshot below... The width of the "title" column is formatted to be 68 bytes. But these "special characters" are taking up more than 1 character width but are only counted as 1 character. This pushes the column past its bounds. print('{0:16s}{3:<18s}{1:68s}{2:>8n}'.format(( ' ' + streamer['user_name'][:12] + '..') if

How can I handle these weird special characters messing my print formatting?

烂漫一生 提交于 2020-12-09 16:26:23
问题 I am printing a formatted table. But sometimes these user generated characters are taking more than one character width and it messes up the formatting as you can see in the screenshot below... The width of the "title" column is formatted to be 68 bytes. But these "special characters" are taking up more than 1 character width but are only counted as 1 character. This pushes the column past its bounds. print('{0:16s}{3:<18s}{1:68s}{2:>8n}'.format(( ' ' + streamer['user_name'][:12] + '..') if

Mapping command s to :w in vim

给你一囗甜甜゛ 提交于 2020-12-08 10:40:56
问题 How can I map Command S to :w in vim? I have tried everything from other threads but nothings seems to work in Mac OS X El Capitan. This supposedly worked in previous versions, but I tried it, and had no success. noremap <silent> <C-S> :update<CR> vnoremap <silent> <C-S> <C-C>:update<CR> inoremap <silent> <C-S> <C-O>:update<CR> Everything on this topic that I could find is several years old and doesn't work anymore. I could find this thread or this thread, but they are both more than three

Mapping command s to :w in vim

元气小坏坏 提交于 2020-12-08 10:39:27
问题 How can I map Command S to :w in vim? I have tried everything from other threads but nothings seems to work in Mac OS X El Capitan. This supposedly worked in previous versions, but I tried it, and had no success. noremap <silent> <C-S> :update<CR> vnoremap <silent> <C-S> <C-C>:update<CR> inoremap <silent> <C-S> <C-O>:update<CR> Everything on this topic that I could find is several years old and doesn't work anymore. I could find this thread or this thread, but they are both more than three

Uninstalling gcc

蓝咒 提交于 2020-12-06 06:53:52
问题 I want to uninstall my gcc by terminal. When I type gcc --version The output is gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609 Copyright (C) 2015 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Could anyone help me? How can I install the last version of gcc after that? 回答1: Use the following command (Replace <version> with the appropriate version): sudo apt

Uninstalling gcc

我只是一个虾纸丫 提交于 2020-12-06 06:52:25
问题 I want to uninstall my gcc by terminal. When I type gcc --version The output is gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609 Copyright (C) 2015 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Could anyone help me? How can I install the last version of gcc after that? 回答1: Use the following command (Replace <version> with the appropriate version): sudo apt

VS Code Open new terminal from powershell

て烟熏妆下的殇ゞ 提交于 2020-12-05 10:02:00
问题 VS Code (Windows 10) What I want to achieve from ps1 script : open 4 terminal tabs first one run python venv and then run django server second one run python venv and then run django shell third one run react (yarn start) fourth normal powershell for git and other I created a powershell script that I run from default opened terminal. Now I'd like to open a new terminal tab from first one. Can I fire a vs code command shortcut (Ctrl+`) or a vs code command palette (Ctrl+Shift+P) from terminal

VS Code Open new terminal from powershell

∥☆過路亽.° 提交于 2020-12-05 09:58:17
问题 VS Code (Windows 10) What I want to achieve from ps1 script : open 4 terminal tabs first one run python venv and then run django server second one run python venv and then run django shell third one run react (yarn start) fourth normal powershell for git and other I created a powershell script that I run from default opened terminal. Now I'd like to open a new terminal tab from first one. Can I fire a vs code command shortcut (Ctrl+`) or a vs code command palette (Ctrl+Shift+P) from terminal