Fix sh scripts
Fix assembly
Add checks to sh script