Details
Description
For instance:
import qbs import qbs.TextFile Product { type: "custom" Transformer { Artifact { fileTags: "custom" fileName: "x" } prepare: { var cmd = new JavaScriptCommand(); cmd.description = "creating file"; cmd.sourceCode = function() { var f = new TextFile(output.filePath, TextFile.WriteOnly); f.close(); } return cmd; } } }
Build this. Now change the file name from "x" to "x/y" and build again. qbs says:
ERROR: Failed to create directory '/tmp/file-then-dir/Host-Qt5-stable-debug/project/x'
This is because the file for the old artifact is still there. Perhaps this is due to us delaying the removal because of artifact rescuing? If so, then solving this would get tricky.