Skip to content

Commit

Permalink
Run Gulp when gulpfile exist
Browse files Browse the repository at this point in the history
  • Loading branch information
realLiangshiwei committed Jan 4, 2022
1 parent 3b023e6 commit f44022e
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ async Task UpdateAsync(string file)
RunYarn(fileDirectory);
}

if (!IsAngularProject(fileDirectory))
if (!IsAngularProject(fileDirectory) && GulpFileExistAsync(fileDirectory))
{
Thread.Sleep(1000);
RunGulp(fileDirectory);
Expand All @@ -108,6 +108,11 @@ private static async Task<bool> NpmrcFileExistAsync(string directoryName)
return await Task.FromResult(File.Exists(Path.Combine(directoryName, ".npmrc")));
}

private static bool GulpFileExistAsync(string directoryName)
{
return File.Exists(Path.Combine(directoryName, "gulpfile.js"));
}

private async Task CreateNpmrcFileAsync(string directoryName)
{
var fileName = Path.Combine(directoryName, ".npmrc");
Expand Down

0 comments on commit f44022e

Please sign in to comment.