'PyCharm hotkey to indent/un-indent a line at caret?

Currently we can move a line up/down by alt+shift+UP and alt+shift+DOWN

Though, when we have moved the line to target position and want to indent it, we have to go to the beginning of the line to tab/shift-tab.

I wonder if we can do that right away at caret position i.e. without having to move to the begin of line.

p.s.

My google results as this page put ctrl+alt+I not work for me.



Solution 1:[1]

As @cdbajorin answered, it's just one more step - selecting a character to indent whole line i.e. no-selection will indent text on the right only.

If you select a single character on the line, tab/shift tab will do the

Solution 2:[2]

By default, the tab key execute action "indent Selection",so you must select some text. there is a keymap named "indent Line or Selection", you can use tab as its shortcut.then you dont need to select text (my pycharm version:2020.1.3)

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Community
Solution 2 qiz_newbie