본문 바로가기

ios

[XCode/iOS] macos, swift 용 .gitignore 생성방법 XCode iOS용 .gitignore 작성 방법 - 모든 작업은 terminal 에서 진행 - git이 설치되어 있음 - .git repository를 프로젝트에 생성해 놓음 1. gitignore 생성관련 git config 환경설정(git 설치 후 최초 1회만 진행) $ git config --global alias.ignore '!gi() { curl -L -s https://www.gitignore.io/api$@; }; gi' 2. gitignore를 추가할 프로젝트 경로로 이동 3. www.gitignore.io 에 등록된 gitignore 생성 (사용할 언어에 대한 ignore 다수 지정 가능 : 빨간색으로 표시) $ git ignore swift,macos > .gitignore 4. 생.. 더보기
[swift3] custom segue transition animation # 오른쪽화면이 왼쪽으로 이동하며 등장 (right to left)# 왼쪽화면이 오른쪽으로 이동하며 등장 (left to right) # 적용 : Segument 선택 > Attributes Inspector 탭 > Kind = Custom 선택, Class = SegueLeftToRight 또는 SegueRightToLeft 선택 끝. 더보기
[iOS] how to create iOS/swift .gitignore in MacOS terminal(console) # console(terminal)에서 iOS/swift .gitignore 생성하기 console(terminal)에서 작업. console(terminal)로 git 프로젝트 이동. https://gitignore.io 에서 ignore 기본값을 받아오도록 git config 설정 ( .gitignore 파일은 아직 생성되지 않음 ) $ git config --global alias.ignore '!gi() { curl -L -s https://www.gitignore.io/api/$@ ;}; gi' .gitignore 에 swift 및 macos 관련 설정 추가 및 적용 ( .gitignore 파일 생성 ) $ git ignore swift,macos > .gitignore 추가한 .gitignor.. 더보기
[swift3] Create Simple Progress Dialog View (ProgressBar, ProgressIndicator, LoadingProgress) - declare - usage - preview 더보기
[swift3] Handler Example Swift 내에서 간단한 Handler를 사용하는 예제 더보기
[swift3] convert Dictionary to Data, Data to String in swift3 1. Dictionary to Datalet dataExample: Data = NSKeyedArchiver.archivedData(withRootObject: dictionaryExample)2. Data to Dictionarylet dictionary: Dictionary? = NSKeyedUnarchiver.unarchiveObject(with: dataExample) as! [String : Any]3. String to Datavar somedata = testString.data(using: String.Encoding.utf8)4. Data to Stringvar backToString = String(data: somedata!, encoding: String.Encoding.utf8) .. 더보기
[iOS]Pods framework not found ... error 1. CocoaPods 다운로드 - sudo gem install cocoapods 2. CocoaPods 설치 - pod setup 3. CocoaPods profile 생성 - pod init 4. 생성된 CocoaPods profile 에 라이브러리 설정# platform :ios, '6.0' 더보기