premake/premake-core

Add copy token that creates non-existing parent directories

Ouverte

#820 ouverte le 17 juin 2017

 (0 commentaire) (0 réaction) (0 personne assignée)C (651 forks)auto 404
enhancementhelp wanted

Métriques du dépôt

Stars
 (3 621 étoiles)
Métriques de merge PR
 (Métriques PR en attente)

Description

Previously, premake allowed to do something like this on Windows:

postbuildcommands {
  "{COPY} %{wks.location}premake5.lua %{wks.location}this/does/not/exist/"
}

...and it created the parent folders like mkdir -p does on Linux.

We relied on that "feature", but since premake automatically omits trailing slashes now, it results in an error. This is probably intended and always behaved like that on Linux, but I think it's actually a pretty handy feature and might make sense to be officially re-introduced on all platforms.

If adding it to {{COPY}} breaks something, I suggest introducing {{COPYP}} or similar instead.

Guide contributeur