Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
忘れないで!mac app!! コマンド編
Search
Akio Itaya
May 23, 2018
1.7k
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
忘れないで!mac app!! コマンド編
potatotips #51
Akio Itaya
May 23, 2018
More Decks by Akio Itaya
See All by Akio Itaya
Androidだけじゃない、DroidKaigiで広がった私の技術スタック
akkeylab
0
79
iOSDCのペンライトを自動制御したい!
akkeylab
0
81
Building a Meta Ray-Ban display app
akkeylab
0
210
What If Your App Could Debug Itself?
akkeylab
0
96
How to stabilize UI tests using XCTest
akkeylab
0
220
Bringing Spatial Web to E-Commerce
akkeylab
0
110
Learn CPU architecture with Assembly
akkeylab
1
2.2k
Porting a visionOS App to Android XR
akkeylab
0
1.2k
How to handle 3D content on Android XR
akkeylab
0
270
Featured
See All Featured
Scaling GitHub
holman
464
140k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
203
76k
Marketing to machines
jonoalderson
1
5.8k
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
2
430
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
2
510
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
1
410
DBのスキルで生き残る技術 - AI時代におけるテーブル設計の勘所
soudai
PRO
68
57k
Build The Right Thing And Hit Your Dates
maggiecrowley
39
3.4k
My Coaching Mixtape
mlcsv
0
320
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
420
First, design no harm
axbom
PRO
2
1.3k
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
890
Transcript
AKKEY / AKIO ITAYA Cyberagent, Inc. Εͳ͍Ͱʂmac appʂʂ ίϚϯυฤ◦
໊લɿ൘୩ ߊྑɹ/ɹ͖͋ͬʔʢAKKEYʣ ৬छɿiOS ׆ಈɿ@AkkeyLab Ұݴɿݸਓ։ൃͬΆ͍ਓؾΞϓϦൃݟͰΔؾഒ૿ ࣗݾհ
ͲΜͳΞϓϦ࡞ͬͯΔਓʁ ※ҙɿݸਓ։ൃ
͔Θ͍͍ΞϓϦ
͔Θ͍͍ΞϓϦ • 1࣌ؒຖʹඒগঁͷͰ࣌ؒΛ͓Βͤʂ • ௨όʔʹඒগঁΠϥετ͕ʂ • ৬Ͱ҆৺ͷϛϡʔτઃఆࡌʂ • ෆఆظͷۀʹؾΛ͚ͭͯͶὑ
͔Θ͍͍ΞϓϦ • 1࣌ؒຖʹඒগঁͷͰ࣌ؒΛ͓Βͤʂ • ௨όʔʹඒগঁΠϥετ͕ʂ • ৬Ͱ҆৺ͷϛϡʔτઃఆࡌʂ • ෆఆظͷۀʹؾΛ͚ͭͯͶὑ
͔Θ͍͍ΞϓϦ • 1࣌ؒຖʹඒগঁͷͰ࣌ؒΛ͓Βͤʂ • ௨όʔʹඒগঁΠϥετ͕ʂ • ৬Ͱ҆৺ͷϛϡʔτઃఆࡌʂ • ෆఆظͷۀʹؾΛ͚ͭͯͶὑ ※৬Ͱͷ༻ࣗݾͰ͓ئ͍͠·͢ɻৗࣝͷൣғͰʂ
͔Θ͍͍ΞϓϦ • 1࣌ؒຖʹඒগঁͷͰ࣌ؒΛ͓Βͤʂ • ௨όʔʹඒগঁΠϥετ͕ʂ • ৬Ͱ҆৺ͷϛϡʔτઃఆࡌʂ • ෆఆظͷۀʹؾΛ͚ͭͯͶὑ ※৬Ͱͷ༻ࣗݾͰ͓ئ͍͠·͢ɻৗࣝͷൣғͰʂ
͔Θ͍͍ΞϓϦ ѪɹশɹɿɹϓϩੜͪΌΜ ɹྸɹɿɹ17ࡀ ৬ɹۀɹɿɹJK ੜɹɿɹ1݄11 ϘΠεɹɿɹ্ࡔ͢ΈΕ Ωϟϥɹɿɹixy ϓϩάϥϛϯάੜ์ૹ ༷ͱͷڠྗ
ͱ͍͏͜ͱͰɺ
mkdir command
Import Cocoa Class ViewController: NSViewController { func create() { let
dir = “\(NSHomeDirectory())/Desktop/swift” let task = NSTask() task.launchPath = “/bin/mkdir” task.arguments = [dir] task.launch() } } ઈରύε
Import Cocoa Class ViewController: NSViewController { func create() { let
dir = “\(NSHomeDirectory())/Desktop/swift” let task = NSTask() task.launchPath = “/bin/mkdir” task.arguments = [dir] task.launch() } }
• Sandbox ͷ༗ແͰऔಘͰ͖ΔσΟϨΫτϦ͕ҧ͏ ແɿ ~/ ༗ɿ ~/Library/Containers/com.app.name/Data/ ҙ Bundle ID
cp command
ίϐʔݩΛબ
Import Cocoa Class ViewController: NSViewController { func copy() { let
panel = NSOpenPanel() panel.canChooseFiles = true panel.canChooseDirectories = false panel.allowsMultipleSelection = false panel.allowedFileTypes = NSImage.imageTypes panel.begin(completionHandler: { num -> Void in if num == NSApplication.ModalResponse.OK, let path = panel.url?.path { Self.read(url: path) } }) } }
Import Cocoa extension ViewController { func read(url: String) { let
home = NSHomeDirectory() task.launchPath = "/bin/cp" task.arguments = [url, home + "/swift/sample"] task.launch() } }
• Sandbox ར༻ͷ߹ઃఆมߋ͕ඞཁ ϑΝΠϧબɿ FileAccess > User Selected File ҙ
ྫɿRead Only
ͥͻɺ༡ΜͰΈ͍ͯͩ͘͞ʂ
GitHub / Qiita : @AkkeyLab
Thank you !!