Skip to content

Commit

Permalink
Aded CreateMissingDirectoriesRule
Browse files Browse the repository at this point in the history
Does what it says on the tin.
  • Loading branch information
vercas committed Dec 30, 2016
1 parent c282dbd commit 8ccf3bb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
4 changes: 2 additions & 2 deletions vmake-1.5.2-12.rockspec → vmake-1.5.3-13.rockspec
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package = "vmake"
version = "1.5.2-12"
version = "1.5.3-13"

source = {
url = "git://github.com/vercas/vMake",
tag = "v1.5.2",
tag = "v1.5.3",
}

description = {
Expand Down
17 changes: 15 additions & 2 deletions vmake.lua
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ if arg then
end

local vmake, vmake__call, getEnvironment = {
Version = "1.5.2",
VersionNumber = 1005002,
Version = "1.5.3",
VersionNumber = 1005003,

Debug = false,
Silent = false,
Expand Down Expand Up @@ -4768,6 +4768,19 @@ function ExcuseMissingFilesRule(ext)
return rule
end

-- Creates a rule which creates missing directories.
function CreateMissingDirectoriesRule(shared)
return Rule "Create Missing Directories" {
Shared = shared or false,

Filter = function(_, dst) return dst.IsDirectory end,

Action = function(_, dst, src)
fs.MkDir(dst)
end,
},
end

-- Parses the GCC-generated Make dependency file associated with the given
-- destination file, if found and possible.
-- Any form of failure results in an empty list being returned.
Expand Down

0 comments on commit 8ccf3bb

Please sign in to comment.