{
    // See https://go.microsoft.com/fwlink/?LinkId=733558
    // for the documentation about the tasks.json format
    "version": "2.0.0",
    "tasks": [
        {
            "label": "clear cache",
            "detail": "Clear the Drupal cache using [Ahoy Drush CR] command. ",
            "type": "shell",
            "command": "ahoy drush cr",
            "problemMatcher": [],
            "presentation": {
                "reveal": "silent"
            }
        },
        {
            "label": "laravel watch",
            "type": "npm",
            "detail": "Run the npm watch command to compile assets using Laravel Mix.",
            "script": "watch",
            "problemMatcher": [],
            "group": {
                "kind": "build",
                "isDefault": true
            },
            "presentation": {
                "reveal": "always",
                "focus": false,
                "clear": true,
                "echo": true,
                "panel": "dedicated",
                "showReuseMessage": true,
                "close": false,
                "group": "utility"
            },
            "options": {
                "cwd": "${workspaceFolder}/web/themes/custom/radix_opc"
            },
            "isBackground": true,
            "runOptions": {
                "instanceLimit": 1,
                "runOn": "folderOpen"
            }
        },
        {
            "label": "lazygit (git)",
            "type": "shell",
            "command": "lazygit",
            "options": {
                "cwd": "${workspaceFolder}/web/themes/custom/radix_opc"
            },
            "presentation": {
                "reveal": "always",
                "focus": true,
                "clear": true,
                "echo": true,
                "panel": "dedicated"
            },
            "problemMatcher": []
        },
        {
            "label": "launch website",
            "detail": "Launch the ahoy hosted website in the default browser.",
            "type": "shell",
            "command": "ahoy info | grep 'http://' | awk -F': ' '/Site local URL/{print $2}' | xargs open",
            "problemMatcher": [],
            "dependsOrder": "parallel",
            "dependsOn": [
                "clear cache"
            ],
            "presentation": {
                "reveal": "silent"
            }
        },
        {
            "label": "login website",
            "detail": "Login the ahoy hosted website in the default browser.",
            "type": "shell",
            "command": "ahoy login  | grep 'http://' | xargs open",
            "problemMatcher": [],
            "dependsOrder": "parallel",
            "dependsOn": [
                "clear cache"
            ],
            "presentation": {
                "reveal": "silent"
            }
        }
    ]
}