반응형

DML문을 실행하려고 했는데 ORA-01950 에러가 발생한다면 해당 테이블스페이스에 insert 할수 있는 권한이 없다는 것이다.

권한을 아래와 같이 부여해 줄 수 있다.

alter user scott quota unlimited on users;

또는


alter user scott quota 1m on users;

 

권한을 확인 하는 방법은 

select * from dba_ts_quotas;

조회하였을때 해당 테이블스페이스의 계정이 등록되어 있으면 권한을 부여받은 것이다.

여기서 max_bytes 가 -1 이면 unlimited 로 부여 받은 것이고, 값이 존재하면 그 byte만큼 저장이 가능하게 부여받은 것이다.

반응형
반응형

오라클에서 제공하는 SQL developer 에서 system 또는 sys 계정에 접속하고자 할 때, 정확한 비밀번호를 입력했음에도 불구하고 접속이 안되는 경우가 있다. 

ORA-01017 에러가 나고 있다.

 

분명 sqlplus에서는 system 계정으로 매우 접속이 잘된다.

SQL> sqlplus /nolog

SQL> conn system/oracle as sysdba

 

왜 이런지 원인은 알 수가 없다. 문제점을 알려주는 곳을 도저히 찾을수가 없었다.

해결방안은 그냥 패스워드를 다시 만들어주면 해결된다. 너무 간단했다. ㅠㅠ

SQL> alter user system identified by "oracle";

 

접속 상태가 성공인 것을 볼 수 있다.

 

참고로 원인을 찾아보던 중 19c 경우 기본암호가 "manager"에서  "no authentication" 로 변경되었다고 하는데,

필자는 초기 기본암호가 "oracle" 이였으며 no authentication 에 대해서는 이해가 되지 않는다. ㅠㅠ

즉, 아래 링크에 대한 글이 이해가 되지 않는다. 누군가 알려주었으면 좋겠다.

https://support.oracle.com/knowledge/Oracle%20Database%20Products/2620296_1.html

 

Default Password For System User("manager") Has Changed In Oracle 19c

Default Password For System User("manager") Has Changed In Oracle 19c (Doc ID 2620296.1) Last updated on JULY 02, 2021 Applies to: Oracle Database - Standard Edition - Version 19.3.0.0.0 and later Oracle Database - Enterprise Edition - Version 19.3.0.0.0 a

support.oracle.com

 

반응형
반응형

$ userdel [사용자아이디]

 

그러나 보통 /home/ 디렉토리에 보면 사용자의 기본 디렉토리가 하나씩은 존재할 것이다.

이 기본 디렉토리까지 전부 삭제해주고 싶다면 옵션을 주자

$ userdel -r [사용자아이디]

 

사용자의 기본 디렉토리가 없어서 혹여나 사용자 계정이 없다고 간과할 수도 있을 것이다.

$ cat /etc/passwd 로 확인 하였을때 사용자가 있는지 확인해봐도 괜찮을 것 같다.

 

 

반응형

'Unix & Linux' 카테고리의 다른 글

[HP-UX] vi 자동들여쓰기(?) 문제  (0) 2022.06.17
리눅스 폴더,파일,vi 컬러 설정  (0) 2022.06.08
terminal too wide  (0) 2022.01.07
CentOS 8 한글 입력  (0) 2021.09.12
cpu, mem 사용량 확인  (0) 2020.10.27
반응형

# 터미널에서 git으로 github 경로를 clone 했을 때 아래와 같이 에러가 발생

$ git clone git@github.com:goodgods/docker-images.git

Cloning into 'docker-images'...
The authenticity of host 'github.com (52.78.231.108)' can't be established.
ECDSA key fingerprint is SHA256:p2QAMXNIC1TJYWrVc98/R1BUu3/LiyUfQM.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'github.com,52.78.231.108' (ECDSA) to the list of known hosts.
git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.

# 해결

$ ssh-keygen -t rsa -C "email "

Generating public/private rsa key pair.
Enter file in which to save the key (/Users/goodgods/.ssh/id_rsa): => ssh가 설치되는 경로,  [Enter] 누른다.
Enter passphrase (empty for no passphrase): => 암호 설정, 암호를 설정하지 않으려면 그냥 [Enter] 누른다.
Enter same passphrase again: => 암호 again
Your identification has been saved in /Users/goodgods/.ssh/id_rsa.
Your public key has been saved in /Users/goodgods/.ssh/id_rsa.pub.
The key fingerprint is:
SHA256:/QA7YAfSjN/wTo+N58yLsPeQdHcubHG7A *****@gmail.com
The key's randomart image is:
+---[RSA 3072]----+
|  .o.=o  .o...   |
|   .+o+o.. o.    |
|    .++.     |
|     +.@S + o    |
|    . o* o  .    |
|     o.o=        |
|    ....o.       |
+----[SHA256]-----+

 

## id_rsa.pub 내용 복사

$ vi /Users/goodgods/.ssh/id_rsa.pub

 

## github 접속 및 로그인

Key값에 ./ssh/id_rsa.pub 파일 내용을 가져온다.

 

## 설치 되었는지 확인 작업

$ ssh -T git@github.com

Hi goodgods! You've successfully authenticated, but GitHub does not provide shell access.

반응형
반응형

SQL> select * from v$diag_info where name = 'Diag Trace';

반응형
반응형

vi 를 누르면 아래와 같이 뜨는 경우가 있다.

Terminal too wide
:

참고로 여길 빠져나갈려면 q를 누르자.

 

stty columns 160 

위 명령어 후 vi 를 하면 정상적으로 작동된다.

반응형

'Unix & Linux' 카테고리의 다른 글

리눅스 폴더,파일,vi 컬러 설정  (0) 2022.06.08
사용자 계정 삭제  (0) 2022.03.18
CentOS 8 한글 입력  (0) 2021.09.12
cpu, mem 사용량 확인  (0) 2020.10.27
특정 데이터를 찾아서 삭제  (0) 2014.07.02
반응형

iOS 15에서 네비게이션 바가  검정색으로 변화되는 현상을 발견하였다.

시뮬레이터에 돌려서 보았을 때는 그런 증상이 있었고,

이 증상을 보자마자 단말기에서도 동일 증상이 있는지 확인 하였으나 발생되지 않았다.

뭐지 하면서 우선 관련되 내용을 찾아보았다.

https://developer.apple.com/forums/thread/683590

 

iOS 15 B2 UINavigationBar Appearan… | Apple Developer Forums

Hey All! When transitioning my app to use the nav bar appearance (introduce in ios13, but required to make navigation bar colors / backgrounds in io15) i believe i had everything all changed over and working ! in iOS 15 b2 it seems when changing navbar bac

developer.apple.com

 

해당 내용을 보고 추가해주었더니 정상 작동을 하였다.

if #available(iOS 15, *) {
    let barAppearance = UINavigationBarAppearance()
    barAppearance.backgroundColor = .white
    navigationItem.standardAppearance = barAppearance
    navigationItem.scrollEdgeAppearance = barAppearance
}

 

반응형
반응형

한글 키보드가 입력되지 않을때 아래와 같이 하자.

필자는 이미 셋팅을 해놓았기 때문에 한글키보드가 되어있으니 참고하길 바란다.

 

설정에 들어가서 왼쪽 메뉴의 "Region & Language"를 선택한다.

Region & Language

"+" 버튼을 누른다.

언어 추가

세로로 "..." 을 되어 있는 More 버튼을 누르고 맨 아래로 내려와 "Other" 을(를) 선택하고, "Kor" 검색한다.

Korean(Hangul)을 선택한다.

그러면 처음 필자가 캡쳐한 화면처럼 Korean(Hangul) 표시가 되었을것이다.

이후 시스템을 재부팅하자. 재부팅을 하지 않으면 적용이 되지 않는다.

 

상단 트레이 한/영 아이콘

시스템 재부팅 후 우측 상단 트레이 부분에 한/영 키가 표시되었을 것이다.

여기서 한글을 선택하면 오른쪽처럼 한글 모드(Hangul mode) 를 켜주면 된다.

한/영 전환은 space + shift 로 전환 할 수 있다.

 

 

 

반응형

'Unix & Linux' 카테고리의 다른 글

사용자 계정 삭제  (0) 2022.03.18
terminal too wide  (0) 2022.01.07
cpu, mem 사용량 확인  (0) 2020.10.27
특정 데이터를 찾아서 삭제  (0) 2014.07.02
메일 서버 사이트  (0) 2014.01.03
반응형

0. 환경

 - vmware fusion 12 (개인계정은 무료)

 - root 계정에서 작업함.

 

1. java 설치

- 호환성 관계로 Java 8 설치

- https://www.oracle.com/java/technologies/javase/javase-jdk8-downloads.html

- 압축을 푼 후 폴더명 변경(jdk-8u301-linux -> jdk1.8)

- /usr/local 로 통채로 폴더 이동

- jdk1.8 안에 바로 bin폴더가 있어야 함. 혹시 폴더를 한번 더 감싸고 있다면 전체 폴더및파일을 앞으로 가져오라

 

2. vi /etc/profile

export JAVA_HOME=/usr/local/jdk1.8
export PATH=$PATH:$JAVA_HOME/bin
export JAVA_OPTS=“-Dfile.encoding=UTF-8”
export CLASSPATH=“.”

$source /etc/profile

$java -version

 

3. hadoop 3.3.1 설치

- https://hadoop.apache.org/releases.html

- 압축을 푼 후 /home/사용자계정 으로 붙여넣기함.

 

4. vi /etc/profile

export HADOOP_HOME=/home/사용자계정/hadoop-3.3.1
export PATH=$PATH:$JAVA_HOME/bin:$HADOOP_HOME/bin:$HADOOP_HOME/sbin
export HDFS_NAMENODE_USER=root
export HDFS_DATANODE_USER=root
export HDFS_SECONDARYNAMENODE_USER=root -> SECONDARAYNAMENODE로 입력해서 계속 에러가 났었음
export YARN_RESOURCEMANAGER_USER=root
export YARN_NODEMANAGER_USER=root

$source /etc/profile

$hadoop version

 

5. 단어세기 프로그램 실행

$hadoop jar $HADOOP_HOME/share/hadoop/mapreduce/hadoop-mapreduce-examples-3.3.1.jar wordcount $HADOOP_HOME/etc/hadoop/hadoop-env.sh wordcount_output

$vi ./wordcount_output/part-r-00000

 

 

# Single Node Cluster

1. ssh 설치

$ yum install openssh

$ /usr/sbin/sshd

$ ssh-keygen -t rsa -P “”

$ cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_keys

$ ssh localhost

……systemctl enable —now cockpit.socket
Last login: Mon Aug 31 16:50:09 2021

위 처럼 나오면 접속 성공

$ exit 빠져 나오기

 

2. hadoop 환경설정

$ vi $HADOOP_HOME/etc/hadoop/hadoop-env.sh

# variable is REQUIRED on ALL platforms except OS X!
export JAVA_HOME=/usr/local/jdk1.8

$ vi $HADOOP_HOME/etc/hadoop/core-site.xml

<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
<property>
<name>fs.defaultFS</name>
<value>hdfs://localhost:9000</value>
</property>
</configuration>

$ vi $HADOOP_HOME/etc/hadoop/hdfs-site.xml

<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
<property>
<name>dfs.replication</name>
<value>1</value>
</property>
</configuration>

3. 하둡 실행

$ hdfs namenode -format

$ start-all.sh

$ jps -> 프로세스 확인 명령어

 

* 데이터 노드가 표기가 되지 않았다면 다시 실행한다.

$ rm -rf /tmp/hadoop-root/dfs/data/
$ stop-all.sh
$ start-all.sh
$ jps

4. hadoop 폴더 생성

$ hdfs dfs -mkdir /user

$ hdfs dfs -mkdir /user/root

$ hdfs dfs -mkdir /user/root/conf

$ hdfs dfs -mkdir /input ->분석할 파일넣는 곳

$ hdfs dfs -copyFromLocal /home/사용자계정/hadoop-3.3.1/README.txt /input -> README.txt 파일을 분석하기위해 input폴더에 넣음.

$ hdfs dfs -ls /input

 

5. wordcount 실행

$ hdfs jar $HADOOP_HOME/share/hadoop/mapreduce/hadoop-mapreduce-examples-3.3.1.jar wordcount /input/README.txt ~/wordcount-output

 

$ hdfs dfs -ls ~/wordcount-output

$ hdfs dfs -cat ~/wordcount-output

반응형

'BigData > Hadoop' 카테고리의 다른 글

[Docker] CentOS에 Hadoop 설치하기  (0) 2022.06.20
반응형

ps auxf

반응형

'Unix & Linux' 카테고리의 다른 글

terminal too wide  (0) 2022.01.07
CentOS 8 한글 입력  (0) 2021.09.12
특정 데이터를 찾아서 삭제  (0) 2014.07.02
메일 서버 사이트  (0) 2014.01.03
cron 메일 수신하기(?)  (0) 2013.08.22
반응형

애플워치5를 사용 중이다.

갑자기 칼로리 계산이 되지 않아 빨간색 바가 계속 0으로 측정되고 있는 것이다.

이것저것 찾아봤지만 마땅한 원인과 해결책을 찾지 못했다.

본 글도 마찬가지로 어떤 이유에서 문제가 생겼는지 정확하게 알 수가 없다.

다만 아래 링크를 확인하여, 위치정보 등 다양한 설정 값이 정확하게 설정되어 있는지 확인해보자.

 

https://support.apple.com/ko-kr/HT204517

 

Apple Watch에서 활동 앱 사용하기

Apple Watch에서 활동 앱을 사용하면 매일 얼마나 움직이고, 운동하고, 일어서 있는지 추적할 수 있습니다. 

support.apple.com

https://support.apple.com/ko-kr/HT204516

 

운동 및 활동의 정확성 향상을 위해 Apple Watch 보정하기

Apple Watch를 보정하여 거리, 속도 및 칼로리 측정의 정확성을 높일 수 있습니다. Apple Watch를 보정하면 체력 수준과 보폭을 파악하는 데도 도움이 되므로 GPS의 사용이 제한적이거나 GPS를 사용할 수

support.apple.com

https://support.apple.com/ko-kr/HT207941

 

Apple Watch를 사용하여 가장 정확한 측정값 얻기

Apple Watch는 사용자가 제공한 개인 정보를 사용하여 일일 활동에 대한 수치를 계산합니다. 다음과 같은 팁을 활용하면 수치의 정확성을 더욱 향상시킬 수 있습니다.

support.apple.com

위 링크를 전부 확인하였지만 제대로 설정이 되어 있었으며, 큰 문제가 되는 곳을 못찾았다.

허나, 한가지 간과하고 넘어간 것이 있었는데, 그것은 개인정보이다.

개인정보를 최신상태로 유지하라고 있다.

나의 설정을 확인해보니, 체중에서 로딩중이라고만 뜨고 바뀔생각을 안하는 것이다.

그래서 체중을 새롭게 설정하였더니, 측정이 되기 시작하였다.

 

이 부분 때문에 측정이 안됐다고는 확실하게 말할 수는 없지만, 아무래도 체중을 알 수 없으니 칼로리 계산을 못한게 아닐까?

체중은 왜 로딩중으로 나왔을까?

 

 

반응형
반응형

We do our best to protect users' personal information in accordance with relevant laws and personal information handling policies.

 

1.Purpose of collecting and using personal information

-We use Google Analytics to improve the service, and the following information may be collected through Google Analytics. (App installation, deletion, update event / Device type and operating system used / App event location, gender, age, funnel path)

-Google Analytics Terms of Service: http://www.google.com/analytics/terms/us.html

-Google Privacy Policy: http://www.google.com/intl/en/policies/privacy/

 

2. Period of retention and use of personal information

-We do not hold and use personal information.

-Google Analytics: You can check the privacy policies of Admob and Google Analytics at https://policies.google.com/privacy?hl=en.

 

3. Procedure and method of destruction of personal information

-We do not collect, use, or hold personal information.

-Admob, Google Analytics: https://policies.google.com/technologies/retention?hl=en

 

4. Sharing personal information and providing it to a third party

 -Personal information items provided: https://policies.google.com/privacy?hl=en#infocollect

 -Retention and use period of the recipient: https://policies.google.com/technologies/retention?hl=en

 

5. Google Privacy Policy and Youtube API Service Terms of Use The "Company" uses the YouTube API service and complies with the Terms of Use and Privacy Policy.

YouTube Terms of Service (https://www.youtube.com/t/terms)

Google Privacy Policy (https://policies.google.com/privacy)

YouTube API Services Terms of Use (https://developers.google.com/youtube/terms/api-services-terms-of-service) 

 

In the event of a situation in which personal information is separately shared or provided with a third party for the provision of services, KidsTube notifies or consents to the user in advance in accordance with the'Act on Promotion of Information and Communication Network Utilization and Information Protection, etc.' and personal information handling policy. I receive it.

반응형
반응형

관계 법령 및 개인정보 취급방침에 따라 사용자 개인정보 보호에 최선을 다합니다. 

 

1.개인정보의 수집 및 이용목적

- 서비스 개선을 위해 Google Analytics 를 사용하고 있으며, Google Analytics 를 통해 다음 정보를 수집할 수 있습니다. (앱 설치, 삭제, 업데이트 이벤트 / 사용 디바이스 기종 및 운영체제 / 앱 이벤트 위치, 성별, 연령, 유입경로)

- Google Analytics 서비스 약관 : http://www.google.com/analytics/terms/us.html

- Google 개인정보보호 정책 : http://www.google.com/intl/en/policies/privacy/

 

2.개인정보의 보유 및 이용기간

- 개인정보를 보유 및 이용하지 않습니다.

- Google Analytics : Admob과 Google Analytics의 개인정보처리방침은 https://policies.google.com/privacy?hl=ko 에서 확인하실 수 있습니다.
 

3.개인정보의 파기 절차 및 방법

- 개인정보를 수집, 이용, 보유하지 않습니다.

- Admob, Google Analytics  : https://policies.google.com/technologies/retention?hl=ko

 

4.개인정보 공유 및 제3자 제공

 - 제공하는 개인정보 항목 : https://policies.google.com/privacy?hl=ko#infocollect

 - 제공받는 자의 보유․이용기간 : https://policies.google.com/technologies/retention?hl=ko

 

5. Google 개인정보 처리방침 및 Youtube API Service 이용 약관"회사"는 YouTube API 서비스를 사용하고 있으며 이용 약관 및 개인 정보 보호 정책을 준수합니다.
YouTube 서비스 약관 (https://www.youtube.com/t/terms)
Google 개인 정보 취급 방침 (https://policies.google.com/privacy)
YouTube API Services 이용약관 (https://developers.google.com/youtube/terms/api-services-terms-of-service)

 

서비스의 제공을 위해 별도로 타사와 개인정보를 공유하거나 제공할 상황이 발생할 경우, 키즈튜브 '정보통신망 이용촉진 및 정보보호 등에 관한 법률'및 개인정보 취급방침에 따라 사용자에게 사전에 고지하거나 동의를 받습니다.

 

반응형
반응형

ituncesconnect 에 빌드된 파일을 업로드 할 때

수출규정 관련 문서가 누락되었다고 느낌표가 뜨는 경우가 있다.

 

이것은 어플에 암호화 기능이 있으면 반드시 추가를 해줘야하는 문서 인것같다.

필자는 암호화 기능을 써본적이 없다.

그래서 항상 무시를 했었다. 무시를 해도 암호화 기능만 없다면 정상적으로 처리가 되었다.

 

느낌표가 나오는 게 찝찝하다면, 아래와 같이 해도 될 것 같다.

xcode에서 info.plist에서 추가한다.

<key>ITSAppUsesNonExemptEncryption</key> <No>

 

 

추가 했을 경우 메세지가 사라졌다.

반응형

'Programming > Swift' 카테고리의 다른 글

cocoapods 설치  (0) 2023.10.18
[iOS15] navigation bar 오류  (0) 2021.09.28
[swift5] 시뮬레이터에 인증서 넣기  (0) 2020.02.25
[Swift5] 아이폰 연결시 에러  (0) 2020.02.03
[Swift5] 문자열에 대한 라인수 구하기  (0) 2020.01.29
반응형

https://github.com/ADVTOOLS/ADVTrustStore

 

ADVTOOLS/ADVTrustStore

ADVTrustStore is a simple management script to import/list/remove CA certificates to the iOS simulator. It is working for iOS 5 and iOS 6. - ADVTOOLS/ADVTrustStore

github.com

보안 관련하여 인증서를 회사에서 받았다. 이후 Xcode 시뮬레이터에서 인터넷이 되지 않았다.

결론은 시뮬레이터에도 동일한 인증서를 넣어주어야 한다.

 

위 사이트를 들어가보면 해결 방안이 잘 나와있다. 

참고로 필자도 위 사이트를 보고 해결하였다.

항상 그랬듯 찾는 시간이 오래 걸리지 해결은 쉬웠다.

 

iosCerTrustManager.py 를 다운 받는다.

$ ./iosCertTrustManager.py --help

$ ./iosCertTrustManager.py -a fileName.pem

subject= CN = goodgods.tistory.com <- 인증서

 

Import certificate to iPhone 11 Pro Max v13.3 [y/N] y

Importing to /Users/comms/Library/Developer/CoreSimulator/Devices/70B8D234-8CD5-43F7-8915-80378BB7116C/data/Library/Keychains/TrustStore.sqlite3

  Certificate added

Import certificate to iPhone 11 v13.3 [y/N] y

Importing to /Users/comms/Library/Developer/CoreSimulator/Devices/8BE1EF1C-42D4-4C17-BC25-685EBB0726C2/data/Library/Keychains/TrustStore.sqlite3

  Certificate added 

 

 

xcode 12에서 안된다면...

1. 파일경로에 한글이 포함된 폴더가 존재하면 안되는 것 같다.

2. 원하는 시뮬레이터를 실행시킨 후에 해보자.

반응형
반응형

실행 오류
상세오류

 

singing 이 맞지 않아서 생긴 문제라고 한다.

signing 부분을 수동으로 관리하고 있었는데, 이부분을 auto로 했더니 잘된다.

 

다만 이렇게 되면 실배포할때는 또 안될 것 같다는 생각이든다.

그럴땐 다시 수동으로 해줘야할 것같은데, Target을 복사해서 singing 부분만 바꿔서 사용해야할지 고민을 해봐야할 것 같다.

 

 

반응형
반응형

let message = "abcdefg\n1234567\n가나다라마바사\nABCDEFG"

let line = message.reduce(into: 0) { (count,letter) in

    if letter == "\n" {

        count += 1

    }

}

 

print(line)

 

https://stackoverflow.com/questions/46490920/count-the-number-of-lines-in-a-swift-string

반응형

'Programming > Swift' 카테고리의 다른 글

[swift5] 시뮬레이터에 인증서 넣기  (0) 2020.02.25
[Swift5] 아이폰 연결시 에러  (0) 2020.02.03
xcode git 연동 문제  (0) 2020.01.16
[swift] slide animation  (0) 2019.11.21
[cocoaPods] 프로젝트 만들어 보기  (0) 2019.10.22
반응형

pc를 재설치하고 Xcode에 git 셋팅 후 작업을 해보았다.

그러나 아래와 같은 메세지를 보여주며 작동이 되지 않는다.

 

이런 경우 Fix 버튼을 눌러서 Author Name, Author Email 값을 넣어준다.

끝.

반응형
반응형

맥에서만 그런건지는 확실하지 않다.

다만 2시간동안 맥에서 삽질을 하면서 알게된 것이다.

 

$ vi /etc/apache2/http.conf

DocumentRoot "/Users/사용자명/www"

<Directory "/Users/사용자명/www">

DocumentRoot 의 값을 설정해 줄 때, 경로를 /Users/사용자명/Documents 로 설정을 해주면

퍼미션 등 500 에러가 뜬다.

원인은 알 수 없으나, 추측하건데 소유자 문제가 아닐지 의심해 본다.

폴더 권한을 777로 줘봐도 같은 에러가 뜬다.

 

결론은 

/Users/사용자명/www 처럼 새로운 폴더를 만들어서 사용을 하자!!

반응형
반응형

case 1.

let transition = CATransition()

transition.type = CATransitionType.push

transition.subtype = CATransitionSubtype.fromLeft

memoView.layer.add(transition, forKey: nil)

memoView.addSubview(countChartView)

memoView.addSubview(closeMemoButton)

case 2.

UIView.transition(with: self.memoView, duration: 1.0, options: [.transitionFlipFromRight], animations: {

      memoView.addSubview(countChartView)

//       self.memoView.removeFromSuperview()

}, completion: nil)

 

 

반응형

'Programming > Swift' 카테고리의 다른 글

[Swift5] 문자열에 대한 라인수 구하기  (0) 2020.01.29
xcode git 연동 문제  (0) 2020.01.16
[cocoaPods] 프로젝트 만들어 보기  (0) 2019.10.22
[iOS13] 당황스럽게 변경된 점  (0) 2019.10.22
[Swift] opacity  (0) 2019.03.22
반응형

본 내용은 2019년 2월 28일에 메모장에 작성된 것을 복붙한 것이다.

기억이 잘 안나지만, 이게 작동이 되었는지는 알 수 없다.

다만 했다는 기억만으로 이렇게 남겨 놓는다.

 

 

1. Github repository 만들기

 

2. cocoaPods 사이트에서 동일한 이름이 있는지 확인하자.

    ex. https://cocoapods.org/pods/mySamplePods 접속하던가, 사이트내에서 검색을 해보아라.

 

3. cocoaPods 프로젝트 만들기

$ pod lib create demoPods

/Users/sk/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/executable.rb:89: warning: Insecure world writable dir /Users/sk/Documents/2016/hadoop/hadoop-1.2.1/sbin in PATH, mode 040777

Cloning `https://github.com/CocoaPods/pod-template.git` into `demoPods`.

Configuring demoPods template.

/Users/sk/Documents/2016/Development/cocoaPods/demoPods/setup/TemplateConfigurator.rb:207: warning: Insecure world writable dir /Users/sk/Documents/2016/hadoop/hadoop-1.2.1/sbin in PATH, mode 040777

security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

 

-----------------------------------------------------------------------------------------------------------------------------

 

To get you started we need to ask a few questions, this should only take a minute.

 

If this is your first time we recommend running through with the guide: 

 - https://guides.cocoapods.org/making/using-pod-lib-create.html

 ( hold cmd and double click links to open in a browser. )

 

 

What platform do you want to use?? [ iOS / macOS ]

 > iOS

 

What language do you want to use?? [ Swift / ObjC ]

 > Swift

 

Would you like to include a demo application with your library? [ Yes / No ]

 > Yes

 

Which testing frameworks will you use? [ Quick / None ]

 > None

 

Would you like to do view based testing? [ Yes / No ]

 > No

security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

security: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.

 

Running pod install on your new library.

 

/Users/sk/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/executable.rb:89: warning: Insecure world writable dir /Users/sk/Documents/2016/hadoop/hadoop-1.2.1/sbin in PATH, mode 040777

Analyzing dependencies

Fetching podspec for `demoPods` from `../`

Downloading dependencies

Installing demoPods (0.1.0)

Generating Pods project

Integrating client project

 

[!] Please close any current Xcode sessions and use `demoPods.xcworkspace` for this project from now on.

Sending stats

Pod installation complete! There is 1 dependency from the Podfile and 1 total pod installed.

 

[!] Automatically assigning platform `ios` with version `9.3` on target `demoPods_Example` because no platform was specified. Please specify a platform for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.

 

 Ace! you're ready to go!

 We will start you off by opening your project in Xcode

  open 'demoPods/Example/demoPods.xcworkspace'

 

To learn more about the template see `https://github.com/CocoaPods/pod-template.git`.

To learn more about creating a new pod, see `http://guides.cocoapods.org/making/making-a-cocoapod`. 

 - 위 keycahin 찾을수없다는 메세지가 나오는데 모르겠음. 

 - 명령어를 실행시킨 위치에서 하위 폴더가 생성 것이다.

 - Xcode 자동 실행된다.

 

4. mySamplePods.podspec 수정

 - 수정할 대상은 s.name, s.version, s.homepage 등이 있다.
 - 하지만 주어진 포맷대로 수정을 해보았지만 오류가 많다.
 - 나의 방법은 그동안 평소 쓰던 다른 사람들이 만들어 놓은 cocoapods GitHub 라이브러리 들어가서 podspec 파일을 가져와서 그대로 수정해주면 된다.

 

5. 파일을 생성하고 스위프트 버전을 넣어준다.

$ vi .swift-version

4.2 <- 버전

6. pod lib lint

 - .podspec 파일을 맞게 작성했는지 체크를 한다.

 

7. Error 체크

 - 에러가 것이다. 여러가지 에러가 나온다. 정말 울화가 치밀어 오른다. 너무 많은 에러를 접했는데 그나마 자주 등장하는 에러만 적어 보았다.

## 1 ##

WARN  | [iOS] swift: The validator used Swift 3.2 by default because no Swift version was specified. To specify a Swift version during validation, add the `swift_version` attribute in your podspec. Note that usage of the `--swift-version` parameter or a `.swift-version` file is now deprecated.
.swift-version 파일을 생성하였지만, 그래도 위와 같은 에러가 발생한다. 이유모름
“pod lib lint —swift-version=4.2” 같이 실행하라.
—swift-version=4.2 옵션은 아래에서도 동일하게 사용된다.

 

## 2 ##
ERROR | [iOS] file patterns: The `resources` pattern did not match any file.
resources 폴더 또는 파일이 존재않는 것이다. 혹은 경로를 잘못 입력하였거나

 

## 3 ##
WARN  | url: The URL (https://github.com/Name/mySamplePods) is not reachable.
유효한 웹페이지를 입력해야한다. 일단 접속되는 아무 URL 입력해도 되는 같음.

 

## 4 ##
demoPods passed validation.
문구가 나오면 성공한 것이다.

 

8. git push

## $ git init  => 존재한다고 하면 그냥 무시.
Reinitialized existing Git repository in /cocoaPods/mySamplePods/.git/


## $ git add -all
## $ git commit -m “Initial commit”
## $ git tag 0.1.0 => 동일 버전을 입력
## $ git remote add origin https://github.com/developer/mySamplePods.git

## $ git push -u origin master —tags => 에러!! ~ 짱나
error: failed to push some refs to 'https://github.com/developer/mySamplePods.git'
=> 이럴 경우 찾아보니 해결 방법은 많은 같더라. 한개 해봤는데 안돼!
## $ git pull --rebase origin master
## $ git push origin master
=> 강제적으로 넣는게 있다고 해서 그냥 이걸로 했음. $ git push origin +master
## github 사이트에가서 제대로 업로드가 되었는지 확인 해보자. 

 

9. CocoaPods 등록 : 인증작업

$ pod trunk register myEamilAddress@gmail.com mySamplePodsTrunk --description=“mySamplePods.PG"

명령어가 실행이 된 후 메일 내용 확인

 

위 메일 내용의 링크를 클릭하면 이와 같은 페이지가 나타난다.

 

10. CocoaPods 등록 : 업로드

$ pod trunk push demoPods.podspec --swift-version=4.2

에러가 나서 확인을 했더니, .podspec 파일의 값이 리셋되어 있는 것이 아닌가 ㅠㅠ
다시 수정하여 재실행 하였다. 결국에는 아래와 같이 나왔다. 성공이다.

수정이 되었는지 알수없다. 다만 git push 할때 강제로 해서 그럴 같다는 생각이 든다.
https://cocoapods.org/pods/mySamplePods 접속을 해보면 접속이된다.

그러나 이 작업이 성공하지 못하면, 잘못된 페이지라고 나올 것이다.

완료된 메세지

11. 이제 사용 해볼까?

현재버전

Xcode 보면 Pods 프로젝트에서 Development Pods 에서 작업을 하면 되는 같다.
Development Pods > mySamplePods > Pod > Classes > *.swift  —> Classes 없으면 만들어 주면 된다.
수정을 했다고 가정하고, .podspec 파일 버전업을 시켜준다.

그리고 위에서 했던 처럼 git 올리고 cocoapods 올리면 된다.
cocoapods 사이트가서 확인해보면 버전이 올라간 것을 확인 있다.

 

버전업

12. 테스트로 임시적으로 프로젝트를 만들어서 pod install 해보자.

반응형

'Programming > Swift' 카테고리의 다른 글

xcode git 연동 문제  (0) 2020.01.16
[swift] slide animation  (0) 2019.11.21
[iOS13] 당황스럽게 변경된 점  (0) 2019.10.22
[Swift] opacity  (0) 2019.03.22
[Swift] UserDefaults.standard int형식으로 불러오기  (0) 2019.02.18
반응형

1. present(_:animated:completion:)

화면전환 시 사용되는 present의 기존 iOS13 이전까지만 해도 default가 fullScreen 이였다.

하지만 iOS13 부터 formsheet가 되었다. 설정을 위해서는 automatic으로 지정해야한다.

그래서 기존 처럼 fullScreen 을 하기 위해서는 아래와 같이 지정한다.

cell.modalPresentationStyle = .fullScreen

self.present(cell, animated: true, completion: nil)

//자세한 내용

https://zeddios.tistory.com/828

https://stackoverflow.com/questions/56435510/presenting-modal-in-ios-13-fullscreen

https://zonneveld.dev/ios-13-viewcontroller-presentation-style-modalpresentationstyle/

 

2. adMob 전면 광고

잘 되던 전면광고가 formSheet처럼 보여지게 되었고, 광고가 전부 보여지지 않고, 반쪽만 보여지게 되었다.

Google-Mobile-Ads-SDK 를 최신버전으로 설치하자.

필자 같은 경우 7.3 버전이였고 7.5로 업데이트를 하였더니, 아무문제 없었다.

 

2-1. adMob 광고

info.Plist에 이것도 추가를 해줘야한다. 앱이 실행되자마자 크래쉬가 된다.

# Error

Google Ad Manager publishers, follow instructions here: https://googlemobileadssdk.page.link/ad-manager-ios-update-plist

위 문구를 찾아보았다.

//https://stackoverflow.com/questions/55577811/xcode-error-when-added-admob-plugin-to-ionic-project

 

info.Plist 에 GADIsAdManagerApp 를 추가하고 Boolean 값으로 YES로 설정해주면 된다.

 

반응형
반응형

아이폰에서 동영상을 편집 후 원본 파일이 사라지고 편집된 파일만 보여진다.

당황하지말고 다시 편집 모드로 들어가 보자.

 

복귀 버튼이 보일 것이다.

복귀 버튼을 터치

 

원본으로 복귀

 

쉽게 해결 가능하다.

 

반응형
반응형

아이폰에서 garageBand를 이용하여 벨소리는 만들었지만 지울수가 없었다.

garabeBand 내에서 삭제할 수 있다고는 하는데,

그것은 어디까지나 garabeBand에서 만들었을 경우에만 해당 될 것으로 생각된다.

 

아이폰내에서는 삭제할 수가 없었으나 아래와 같은 방법으로 삭제 할 수 있었다.

 

1. iFunBox 다운로드(http://www.i-funbox.com/en_download.html) 및 설치

2. 아이폰과 연결

3. Raw File System > Purchases

4. Ringtones.plist 를 열어 각 리스트를 펼쳐보면, 자신이 만든 벨소리를 확인 할 수 있다.

 Name을 확인한 후에 import로 시작하는 파일명을 확인한다.

5. 위 해당 목록과 파일명을 삭제해주면 된다.

반응형
반응형

UIView를 반투명하려면 opacity를 사용한다.

let background = UIView()

background.layer.backgroundColor = UIColor.black.cgColor

background.layer.opacity = 0.5 


하지만 이 뷰안에 다른 레이블이 포함되었을 경우, 포함된 레이블도 같이 투명하게 되는 경우가 있다.

let background = UIView()

background.layer.backgroundColor = UIColor.black.cgColor

background.layer.opacity = 0.5

let title = UILabel()

backgroud.addSubview(title)


이럴 경우 이렇게 해보자

let background = UIView()

background.layer.backgroundColor = (UIColor.black.cgColor).copy(alpha: 0.5)

let title = UILabel()

background.addSubview(title)


반응형
반응형

        // 저장할때는 동일하다.

        UserDefaults.standard.set(5, forKey:"num")

        

        // 불러올 때

        UserDefaults.standard.integer(forKey: "num")


반응형
반응형

        let taskText = "All Tasks (task)"

        let attributed = NSMutableAttributedString(string: taskText)

        let strokeTextAttributes = [

//            NSAttributedString.Key.strokeColor : UIColor.black,

            NSAttributedString.Key.foregroundColor : UIColor.black,

//            NSAttributedString.Key.strokeWidth : 2.0,

            NSAttributedString.Key.font : UIFont.boldSystemFont(ofSize: 18)

            ] as [NSAttributedString.Key : Any]

        

        attributed.addAttributes(strokeTextAttributes, range: (taskText as NSString).range(of: "(task)"))

        titleLabel.attributedText = attributed



반응형
반응형

    func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {

        // Override point for customization after application launch.

        UINavigationBar.appearance().barTintColor = UIColor.white//.init(red: 23.0/255, green: 197.0/255, blue: 157.0/255, alpha: 1.0)

        

        // To change colour of tappable items.

        UINavigationBar.appearance().tintColor = .black

        

        // To apply textAttributes to title i.e. colour, font etc.

        UINavigationBar.appearance().titleTextAttributes = [.foregroundColor : UIColor.black, .font : UIFont.init(name: "AvenirNext-DemiBold", size: 22.0)!]

        

        // To control navigation bar's translucency.

        UINavigationBar.appearance().isTranslucent = false


        return true

    }


반응형
반응형

override func viewDidLoad() {

        super.viewDidLoad()

        self.navigationController?.navigationBar.setBackgroundImage(UIImage(), for: UIBarMetrics.default)

        self.navigationController?.navigationBar.shadowImage = UIImage()

}


반응형
반응형

이미지를 클릭 하시면 다운로드 받으실 수 있습니다.

유아색칠놀이



이제 막 걸음마를 배우는 우리 아이에게 재미있는 어플을 소개 해 드리겠습니다.

아주아주 단순한 어플입니다.

특별한 기능도 없고, 손가락으로 쓱쓱싹싹 문질러주기만 하면, 그림이 완성된답니다.


단순하지만, 아이에게는 신기한 어플이 아닐까 생각됩니다.




유아색칠놀이 메인 화면입니다.

첫번째는 랜덤, 두번째는 이미지 선택 세번째는 설정으로 총 3개의 버튼이 있습니다.




  

기본적으로 68개의 이미지를 선택 할 수 있습니다.

그리고 추가적으로 내 사진에서도 선택할 수도 있습니다.




이것이 색칠을 하는 화면입니다.

첫화면에서 첫번째와 두번째 버튼을 눌렀을 때 나오는 화면이고,

랜덤을 선택 하였을 경우에는 색칠이 완료 되었을 때 쯤, 다음 그림으로 자동으로 넘어갑니다.

(이미지 10개까지)

위 이미지는 부분적으로 쓱쓱싹싹 문지른 상태입니다.




설정 화면입니다.

첫 번째 버튼은 스케치 모드와 흑백모드를 디폴트로 설정할 수 있습니다.

아래 이미지는 스케치와 흑백 모드에 따른 보여지는 화면입니다.




.

.

.


다음 


연필모양 버튼은 디폴트로 브러쉬 크기를 설정할 수 있습니다.

일회성으로 게임중에서도 선택할 수 있습니다.





세번째 카트모양의 버튼은 기본 68개의 이미지 외 새로운 이미지를 추가 할 수 있습니다.

다만 광고를 시청 후에 3개의 이미지를 다운받을 수가 있습니다.






불필요한 광고라고 생각하시겠지만, 

개인 개발자들의 광고는 앱을 유지보수 하는데 많은 도움이 될 수 있습니다.

이 점 깊은 양해 부탁드립니다.





개발자의 말!


제목에서 보셨듯이, 해당 앱이 색칠이 아닐 수도 있습니다.

손가락으로 문지르면 색이 보여지는 게 하는 것이 색칠 하는 것과 같다고 판단하였습니다.


이제 막 걸음마를 배우는 아이들이 쉽게 접할 수 있을 것 같습니다.



변화해야한다는 점이 많다고 생각합니다.

향후 계획은 정말 색칠되는 것처럼 보여주는 것이 개인적인 목표입니다.


반응형

'Introduction to the applications' 카테고리의 다른 글

KidsTube Privacy policy  (0) 2020.07.07
키즈튜브 개인정보처리방침  (0) 2020.07.07
Privacy policy  (0) 2018.10.09
개인정보처리방침  (0) 2018.10.03
[iOS] QR코드!! 읽고 쓰기를 동시에?  (0) 2018.09.28

+ Recent posts