PyCharm 2018.2 Help

Keymap:

Saving and Reverting Changes

PyCharm automatically saves changes that you make in your files. Saving is triggered by various events, such as compiling, running, debugging, performing version control operations, closing a file or a project, or quitting the IDE entirely. The actual events are predefined and cannot be configured, but you can be sure that changes will not be lost as you work.

To force saving all your files, open the File menu and click Save All, or press Ctrl+S.

Configure autosave behavior

Open Settings / Preferences, expand Appearance and Behavior, and click System Settings.

Under Synchronization, configure the following options:

Save files on frame deactivation (when you switch to a different application)