0
0

VSCode+PythonでAtCoderを自動提出(の補足)

Last updated at Posted at 2024-08-18

基本的にはこの記事を参考にすると良い。補足として…

  • 例えば「アルゴリズムと数学」について、VSCodeにディレクトリが自動作成するためには、acc new math-and-algorithmを実行すれば良い。
  • ローカル環境に複数のPython環境が複数ある場合は、tasks.jaonを以下のように変更すると良い。
tasks.json
{
  "version": "2.0.0",
  "tasks": [
    {
      "label": "CheckTestCase",
      "type": "shell",
      "command": "cd ${fileDirname} && oj t -c 'python3 main.py' -d ./tests/",
      "presentation": {
        "reveal": "always",
        "focus": true,
        "panel": "shared"
      }
    },
    {
      "label": "SubmitCode",
      "type": "shell",
      "command": "cd ${fileDirname} && acc s ${fileBasename} -- --langage:xxx",  // 変更点。xは使用するPythonインタープリタ
      "presentation": {
        "reveal": "always",
        "focus": true,
        "panel": "shared"
      }
    }
  ]
}
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0