Skip to content

Commit 3be5607

Browse files
committed
experimental sleep to solve problem of writing files (seems not working though)
1 parent 506b42e commit 3be5607

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

mrbgems/picoruby-shell/mrblib/shell.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ def self.setup_system_files(root = nil, force: false)
4343
Dir.chdir(root || "/") do
4444
%w(bin lib var home etc etc/init.d etc/network).each do |dir|
4545
Dir.mkdir(dir) unless Dir.exist?(dir)
46+
sleep_ms 100
4647
end
4748
while exe = Shell.next_executable
4849
path = "#{root}#{exe[:path]}"
@@ -51,6 +52,7 @@ def self.setup_system_files(root = nil, force: false)
5152
f.expand exe[:code].length if f.respond_to? :expand
5253
f.write exe[:code]
5354
f.close
55+
sleep_ms 100
5456
end
5557
end
5658
path = "#{root}/etc/machine-id"

0 commit comments

Comments
 (0)