Переглядів 1,840
In iOS and macOS projects, I often deal with some sort of setup or maintenance scripts written in Bash. But because it is so different from Swift-my primary programming language-I don’t feel very confident working with Bash. In this video, I explore scripting in Swift: turns out, it’s a pretty good alternative suitable for most use cases.
You can support me by…
• …buying me a coffee: www.buymeacoffee.com/SwiftBird
• …becoming a patron: / swiftbird
Links:
• Scripting in Swift basics: rderik.com/blog/using-swift-f...
• FileManager documentation: developer.apple.com/documenta...
• FileManager basics: nshipster.com/filemanager/
• Swift extension for VS Code: marketplace.visualstudio.com/...
• Homebrew on Linux: docs.brew.sh/Homebrew-on-Linux
Chapters:
• 0:00 Intro
• 0:56 What’s Wrong with Bash?
• 2:11 Where You Can Use Swift Scripts
• 2:54 Swift vs. Bash for Scripting
• 4:00 Environment Setup
• 6:13 Basic Operations: Printing, Reading Input, Calling Functions, etc.
• 9:14 Calling Other Commands
• 14:23 Reading and Writing Files
• 16:51 Two Forms: Interpreted and Binary
• 19:16 Summary
• 19:35 Outro
The Swift Bird is produced by / yakovmanshin .
#swift #script #softwareengineering