Skip to content

Commit 071c562

Browse files
committed
fix BAD_MPY being undefined and skip dot-files in circup
1 parent 84064c5 commit 071c562

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

assets/lib/circup.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,13 @@ function semver_compare(a,b) {
1818
)
1919
}
2020

21+
function ignore_file(file_name) {
22+
return file_name.match(/(^\.|\/\.)/) ? true : false
23+
}
24+
2125
class Circup {
2226
static BAD_MPY = -1
27+
BAD_MPY = Circup.BAD_MPY
2328

2429
constructor(library_bundle, workflow) {
2530
this.library_bundle = library_bundle
@@ -95,6 +100,7 @@ class Circup {
95100

96101
var version = false
97102
for(var file_name of module_files) {
103+
if(ignore_file(file_name)) { continue }
98104
var file_path = ("/" + file_name).replace(/\/\/+/, "/")
99105
var response = await this.workflow.get_file_content(file_path)
100106
if(!response.ok) { continue }

0 commit comments

Comments
 (0)