SlideShare ist ein Scribd-Unternehmen logo
1 von 31
Downloaden Sie, um offline zu lesen
Custom Xcode Template
(with VIPER)
let us: Go!
2017 Summer
giftbot(t)
Xcode Template
1. VIPER 아키텍처 소개 및 코드 작성
2. File Template 을 이용한 바이퍼 모듈 생성
3. Project Template 으로 테스트 프로젝트 생성
4. Custom Template 만들어보기
T.O.C
MVC MVP MVVM
VIPER
Protocols
VIPER 모듈
한 땀 한 땀 만들어보기
VIPER Module Generator
• Generamba
• Boa
• viper-module-generator
해당 라이브러리에 대한 별도의 이해 및 설정 필요
별도의 스크립트 형태 - 터미널에서 실행
그래서...
Custom File Template
File Template
Swift File
TemplateInfo.plist
Kind
파일 템플릿 타입
Xcode.IDEKit.TextSubstitutionFileTemplateKind
AllowedTypes
생성 파일 타입
Swift : public.swift-source
Platforms
사용할 플랫폼
iOS : com.apple.platform.iphoneos
MainTemplateFile
생성 파일 이름 Base
ex) ___FILEBASENAME___.swift
SortOrder 템플릿간 정렬 우선순위
매크로
___FILENAME___
파일명 (확장자 포함)
ex) ViewController.swift
___FILEBASENAME___
파일명 (확장자 미포함)
ex) ViewController
___PROJECTNAME___ 프로젝트명
___ORGANIZATIONNAME__
_
조직명
___FULLUSERNAME___ 유저명 (FullName)
___DATE___ 현재 날짜
___VARIABLE_[Identifier]___ Identifier에 해당하는 변수값
옵션
옵션
Identifier ID. 변수 역할
Name 해당 옵션의 Label Text
Default 미입력시 기본값
Type
옵션 타입.
text, combo, popup, class, checkbox, … 등
NotPersisted 마지막 사용 값 저장 여부
Required 필수 설정 여부
Suffixes 옵션 변경 시 파일명 뒤에 자동으로 붙는 문자열
“~/Library/Developer/Xcode/Templates/File Templates/”
User Custom Path
1. iOS 플랫폼용 - “[Xcode Path]/Platforms/iPhoneOS.platform/Developer/
Library/Xcode/Templates/File Templates/”
2. 공용 - “[Xcode Path]/Library/Xcode/Templates/File Templates/“
Xcode Application Path
Custom File Template 만들기
1. Swift File Template 복사 (시작하기 좋은 템플릿)
2. Change Owner (root => user)
3. TemplateInfo.plist 수정
4. 커스텀 파일 작성
Project Template
Single View Application
Kind
프로젝트 템플릿 타입
Xcode.Xcode3.ProjectTemplateUnitKind
Identifier
Template Unique ID. 반드시 고유한 값을 가져야 함.
ex) com.apple.dt.unit.singleViewApplication
Ancestors 다른 템플릿에 설정한 내용을 상속받아 사용
Concreate
true 일 때만 Dialog에 나타남.
false 는 다른 템플릿에 상속하여 쓰는 경우.
Definitions 템플릿에서 사용할 내용을 미리 정의
Nodes Definitions에서 정의한 내용 불러오기 / 바로 구현
TemplateInfo.plist
주의사항
com.apple.dt.unit.singleViewApplication
cocoaTouchApplicationBase
coreDataCocoaTouchApplication storyboardApplication
iosBase applicationBase languageChoice
iosBase_Definitions bundleBase
base
base_DefinitionsLanguage base_DefinitionsInfoPlist base_ProjectSettings base_Options
User Custom Path
“~/Library/Developer/Xcode/Templates/Project Templates/”
1. iOS 플랫폼 - “[Xcode Path]/Platforms/iPhoneOS.platform/Developer/
Library/Xcode/Templates/Project Templates/iOS/”
2. 공용 - “[Xcode Path]/Library/Xcode/Templates/Project Templates/“
Xcode Application Path
Custom Project Template 만들기
1. Single View Application 복사 (시작하기 좋은 템플릿)
2. Change Owner (root => user)
3. Customizing
• TemplateInfo.plist Definitions 에서 정의
• Custom File 생성
4. TemplateInfo.plist Nodes 에 반영
직접 만들어볼까요?
https://github.com/giftbott/XcodeTemplateHelper
Q & A

Weitere ähnliche Inhalte

Was ist angesagt?

자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012
자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012
자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012
Esun Kim
 
ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사
ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사
ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사
제관 이
 

Was ist angesagt? (20)

20220716_만들면서 느껴보는 POP
20220716_만들면서 느껴보는 POP20220716_만들면서 느껴보는 POP
20220716_만들면서 느껴보는 POP
 
자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012
자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012
자동화된 소스 분석, 처리, 검증을 통한 소스의 불필요한 #if - #endif 제거하기 NDC2012
 
Boas práticas técnica para um código limpo (Clean Code)
Boas práticas técnica para um código limpo (Clean Code)Boas práticas técnica para um código limpo (Clean Code)
Boas práticas técnica para um código limpo (Clean Code)
 
Testes de segurança em aplicações web
Testes de segurança em aplicações webTestes de segurança em aplicações web
Testes de segurança em aplicações web
 
C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.C++ Restrictions for Game Programming.
C++ Restrictions for Game Programming.
 
A Framework Driven Development
A Framework Driven DevelopmentA Framework Driven Development
A Framework Driven Development
 
Python games
Python gamesPython games
Python games
 
안드로이드 윈도우 마스터 되기
안드로이드 윈도우 마스터 되기안드로이드 윈도우 마스터 되기
안드로이드 윈도우 마스터 되기
 
Bad Code Smells
Bad Code SmellsBad Code Smells
Bad Code Smells
 
[2013 CodeEngn Conference 09] Park.Sam - 게임 해킹툴의 변칙적 공격 기법 분석
[2013 CodeEngn Conference 09] Park.Sam - 게임 해킹툴의 변칙적 공격 기법 분석[2013 CodeEngn Conference 09] Park.Sam - 게임 해킹툴의 변칙적 공격 기법 분석
[2013 CodeEngn Conference 09] Park.Sam - 게임 해킹툴의 변칙적 공격 기법 분석
 
Magento Docker Setup.pdf
Magento Docker Setup.pdfMagento Docker Setup.pdf
Magento Docker Setup.pdf
 
PHP で実行中のスクリプトの動作を下から覗き見る
PHP で実行中のスクリプトの動作を下から覗き見るPHP で実行中のスクリプトの動作を下から覗き見る
PHP で実行中のスクリプトの動作を下から覗き見る
 
Understanding CSS Selectors in Selenium.pdf
Understanding CSS Selectors in Selenium.pdfUnderstanding CSS Selectors in Selenium.pdf
Understanding CSS Selectors in Selenium.pdf
 
Yacc lex
Yacc lexYacc lex
Yacc lex
 
Hardware Acceleration in WebKit
Hardware Acceleration in WebKitHardware Acceleration in WebKit
Hardware Acceleration in WebKit
 
MFC Message Handling
MFC Message HandlingMFC Message Handling
MFC Message Handling
 
Clean code presentation
Clean code presentationClean code presentation
Clean code presentation
 
[부스트캠퍼세미나]조성동_야_너두_TDD_할_수_있어
[부스트캠퍼세미나]조성동_야_너두_TDD_할_수_있어[부스트캠퍼세미나]조성동_야_너두_TDD_할_수_있어
[부스트캠퍼세미나]조성동_야_너두_TDD_할_수_있어
 
ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사
ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사
ISMS 개발보안, 시큐어코딩을 위한 sonarqube의 활용.건국대학교병원.이제관 기술사
 
Introducing java oop concepts
Introducing java oop conceptsIntroducing java oop concepts
Introducing java oop concepts
 

Ähnlich wie Custom Xcode Template (with VIPER)

효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
Amazon Web Services Korea
 
V8 add on with middleware modules
V8 add on with middleware modulesV8 add on with middleware modules
V8 add on with middleware modules
Jay Kim
 

Ähnlich wie Custom Xcode Template (with VIPER) (20)

생산성을 높여주는 iOS 개발 방법들.pdf
생산성을 높여주는 iOS 개발 방법들.pdf생산성을 높여주는 iOS 개발 방법들.pdf
생산성을 높여주는 iOS 개발 방법들.pdf
 
20170310 tech day-1st-maven을 이용한 프로그램 빌드-박준홍
20170310 tech day-1st-maven을 이용한 프로그램 빌드-박준홍20170310 tech day-1st-maven을 이용한 프로그램 빌드-박준홍
20170310 tech day-1st-maven을 이용한 프로그램 빌드-박준홍
 
프로젝트 아나키로 Rpg 만들기 프로그래밍
프로젝트 아나키로 Rpg 만들기 프로그래밍프로젝트 아나키로 Rpg 만들기 프로그래밍
프로젝트 아나키로 Rpg 만들기 프로그래밍
 
Springmvc
SpringmvcSpringmvc
Springmvc
 
20240325 TuistNight 모듈로 나누면 알아두면 좋을 3가지 팁
20240325 TuistNight 모듈로 나누면 알아두면 좋을 3가지 팁20240325 TuistNight 모듈로 나누면 알아두면 좋을 3가지 팁
20240325 TuistNight 모듈로 나누면 알아두면 좋을 3가지 팁
 
스프링 스터디 1장
스프링 스터디 1장스프링 스터디 1장
스프링 스터디 1장
 
Unity Auto Build iOS
Unity Auto Build iOSUnity Auto Build iOS
Unity Auto Build iOS
 
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
효과적인 데브옵스를 위한 AWS 개발 도구 활용하기 - AWS Summit Seoul 2017
 
Eclipse 4 RCP - 2nd Week
Eclipse 4 RCP - 2nd WeekEclipse 4 RCP - 2nd Week
Eclipse 4 RCP - 2nd Week
 
웹 IDE 비교
웹 IDE 비교웹 IDE 비교
웹 IDE 비교
 
Metaworks3 Framework workbook 2015
Metaworks3 Framework workbook 2015Metaworks3 Framework workbook 2015
Metaworks3 Framework workbook 2015
 
Portfolio
PortfolioPortfolio
Portfolio
 
ant로 안드로이드 앱을 자동으로 빌드하자
ant로 안드로이드 앱을 자동으로 빌드하자ant로 안드로이드 앱을 자동으로 빌드하자
ant로 안드로이드 앱을 자동으로 빌드하자
 
AWS Meetup 프리젠테이션.pdf
AWS Meetup 프리젠테이션.pdfAWS Meetup 프리젠테이션.pdf
AWS Meetup 프리젠테이션.pdf
 
letswift22_우당탕탕 확장 프로그램(이다혜 light).pdf
letswift22_우당탕탕 확장 프로그램(이다혜 light).pdfletswift22_우당탕탕 확장 프로그램(이다혜 light).pdf
letswift22_우당탕탕 확장 프로그램(이다혜 light).pdf
 
[KGIT_EWD]class03 0322
[KGIT_EWD]class03 0322[KGIT_EWD]class03 0322
[KGIT_EWD]class03 0322
 
인프콘 2022 - Rust 크로스 플랫폼 프로그래밍
인프콘 2022 - Rust 크로스 플랫폼 프로그래밍인프콘 2022 - Rust 크로스 플랫폼 프로그래밍
인프콘 2022 - Rust 크로스 플랫폼 프로그래밍
 
AWS Code 서비스 특집 - 아마존 DevOps와 CodeDeploy, CodePipeline (윤석찬)
AWS Code 서비스 특집 - 아마존 DevOps와 CodeDeploy, CodePipeline (윤석찬)AWS Code 서비스 특집 - 아마존 DevOps와 CodeDeploy, CodePipeline (윤석찬)
AWS Code 서비스 특집 - 아마존 DevOps와 CodeDeploy, CodePipeline (윤석찬)
 
V8 add on with middleware modules
V8 add on with middleware modulesV8 add on with middleware modules
V8 add on with middleware modules
 
java thrift
java thriftjava thrift
java thrift
 

Mehr von Bongwon Lee (8)

DeprecatedAPI로 알아보는 SwiftUI
DeprecatedAPI로 알아보는 SwiftUIDeprecatedAPI로 알아보는 SwiftUI
DeprecatedAPI로 알아보는 SwiftUI
 
Swift in SwiftUI
Swift in SwiftUISwift in SwiftUI
Swift in SwiftUI
 
App Lifecycle
App LifecycleApp Lifecycle
App Lifecycle
 
GraphQL over REST
GraphQL over RESTGraphQL over REST
GraphQL over REST
 
The Sandbox Container Directory
The Sandbox Container DirectoryThe Sandbox Container Directory
The Sandbox Container Directory
 
Simulator customizing & testing for Xcode 9
Simulator customizing & testing for Xcode 9Simulator customizing & testing for Xcode 9
Simulator customizing & testing for Xcode 9
 
LetSwift 2017 - ARKit
LetSwift 2017 - ARKitLetSwift 2017 - ARKit
LetSwift 2017 - ARKit
 
Realm, Mobile Database
Realm, Mobile DatabaseRealm, Mobile Database
Realm, Mobile Database
 

Custom Xcode Template (with VIPER)