컴퓨터/git

git repository 생성

풍경소리^^ 2024. 7. 26. 15:37

https://www.youtube.com/watch?v=PhCwwbjNuSw

 

 

github.com/계정ID

 

repository 생성 - vba_vscode_git

 

vscode

 

ctrl+`

dir

 

.gitconfig 있는지 확인 후

 

cat .gitconfig

[user]
        name = 이름
        email = 이메일

 

재설정

git config --global user.name "계정이름"

git config --global user.email "이메일"

 

list

cat .gitconfig

확인하기

 

github.com/계정ID

 

https://github.com/계정ID/vba_vscode_git.git

 

vscode

리포지토리 복제

Clone from GitHub

위 git 리포지토리 선택

내컴퓨터 로컬 폴더 생성할 상위 폴더 선택

 

좌측 하단에 main 가지 누르면

 

create new branch 다른가지 만들기 연습

 

내부 파일 수정하면

소스제어(좌측에 git아이콘)

>changes

+ (플러스버튼)

>Sraged Changes

>Source Control

제목작성

Commit

Publish Branch 새로운 가지 생성

 

main 가지 누르고

merge - Git: Merge Branch

병합할 가지 클릭

 

소스제어(좌측에 git아이콘)

 

Sync Changes 1 ↑

ok

 

확장

live server 설치

xvba-live server vba 설치

 

엑셀

파일-옵션

보안센터-보안센터설정

매크로설정-모든 매크로 포함

 

vscode

좌측하단

XVBA-MACRO LIST 클릭

Bootstrap XVBA Config

Create Excel VBA Project 클릭

 

vba-files선택

New file

 

first.bas----------------------------------------

x-m입력 후 file

Attribute VB_Name = "first"

x-su입력 후 x-pbSub

Public  Sub say_hello()

    MsgBox "miero",,"title" 

End Sub

 

excel

B:\excel\vba_vscode_git 경로에

index.xlsb

 

XVBA-MACRO LIST 클릭

Export VBA

Development

 

<s> say_hello > 매크로실행

 

코드 추가

Public  Sub greetings()

    Range("B2").value = "miero"

End Sub

 

XVBA-MACRO LIST

Export VBA

Development

 

<s> greetings > 매크로실행

 

한글깨짐

 

하단 가운데

EUC-KR 로 바꾸어 주어야 한다

 

https://happy-hee8.tistory.com/101

 

Visual Studio Code 한글 깨짐 문제 해결 (& Live Server)

다른분이 작업하셨던 파일을 받아서 작업을 하려고 vscode의 플러그인인 live server로 index.html 파일을 실행했다. 그런데 페이지가 열리자마자 아주 당황했다. 한글이 전부 깨져서 나온 것이다😂 이

happy-hee8.tistory.com

 

excel

Alt+F11

Public Sub greetings()

    Range("B2").value = "miero"
    
    Range("B3").value = hello

End Sub

Private Function hello()
    hello = "Saying miero"
End Function

 

vscode 

XVBA-MACRO LIST

import - VBA

 

Module-first.bas생김

원래 있던 first.bas 삭제

 

greetings > 매크로실행

 

소스제어(좌측에 git아이콘)

변경사항>

+ (플러스버튼)

 

제목 달기

엑셀 export import

커밋

상단 체크