Skip to content

Instantly share code, notes, and snippets.

@Luocy7
Created July 6, 2023 03:04
Show Gist options
  • Save Luocy7/9508ad521a4cb29405ad02ea4f8d0221 to your computer and use it in GitHub Desktop.
Save Luocy7/9508ad521a4cb29405ad02ea4f8d0221 to your computer and use it in GitHub Desktop.
Pycharm black&poetry export tools
<toolSet name="External Tools">
<tool name="Black" description="Black is the uncompromising Python code formatter." showInMainMenu="false" showInEditor="false" showInProject="false" showInSearchPopup="false" disabled="false" useConsole="false" showConsoleOnStdOut="false" showConsoleOnStdErr="true" synchronizeAfterRun="true">
<exec>
<option name="COMMAND" value="$PyInterpreterDirectory$/black" />
<option name="PARAMETERS" value="$FilePath$" />
<option name="WORKING_DIRECTORY" value="$ProjectFileDir$" />
</exec>
</tool>
<tool name="Poetry Export" description="poetry export to requirements.txt" showInMainMenu="false" showInEditor="false" showInProject="false" showInSearchPopup="false" disabled="false" useConsole="false" showConsoleOnStdOut="false" showConsoleOnStdErr="true" synchronizeAfterRun="true">
<exec>
<option name="COMMAND" value="poetry" />
<option name="PARAMETERS" value="export --without-urls --without-hashes -o requirements.txt" />
<option name="WORKING_DIRECTORY" value="$ProjectFileDir$" />
</exec>
</tool>
</toolSet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment