bash 스크립트 작성 중 질문

gksrb500의 이미지

계산화학을 하고 있는 학생입니다. 계산 결과값을 손으로 직접 정리하기엔 단순 작업량이 굉장히 많아 코딩을 이용해 간단하게 해결하고자 했습니다.

아래 파일을 첨부하였습니다.

제가 하고 싶은 것은 아래 파일에서 'Optimization completed' 라는 문구가 나오고, 그 위에 있는 standard orientation 을 복사하여 새로운 텍스트 파일에 붙이는 것 입니다. 또한 Atomic number 라는 열에서는 7은 N, 1은 H, 14는 Si로 치환하여 나타내고 싶습니다.

좀더 설명하고자 파일의 일부분을 가져오면,

Standard orientation:
---------------------------------------------------------------------
Center Atomic Atomic Coordinates (Angstroms)
Number Number Type X Y Z
---------------------------------------------------------------------
1 7 0 -0.052963 1.214246 -0.000000
2 1 0 0.484249 1.521097 0.814525
3 1 0 0.484249 1.521097 -0.814525
4 14 0 -0.052963 -0.631573 0.000000
5 1 0 -0.634200 -1.219249 1.239574
6 1 0 -0.634200 -1.219249 -1.239574
7 1 0 1.412117 -0.261395 0.000000
---------------------------------------------------------------------
Rotational constants (GHZ): 66.3317637 11.7756446 11.4424088
Standard basis: def2SVP (5D, 7F)

.
. (중략)
.

Optimization completed.

.
. (생략)
.

이런 식의 구조로 되어있습니다. 제가 원하는 건 아무 Standard orientation 이 아닌, optimization completed. 라는 문구가 뜬 곳마다 위에 있는 standard orientation의 바로 아래 표만 복사하여 새로운 텍스트 파일에 복사하여 넣고 싶습니다. 또한 optimization completed는 여러 개가 있어서 표도 그만큼 복사해야 합니다.

감사합니다.

File attachments: 
첨부파일 크기
Plain text icon Si1N.txt902.98 KB
황병희의 이미지

코드가 쌈빡하지 못한점 죄송합니다.
그리고 3개의 문자열 치환은 구현 못했네요.

파이썬3 입니다.

#!/usr/bin/env python3 
# -*- coding: utf-8 -*-
 
# KLDP 164504
 
def _get_url(xyz):
    from subprocess import Popen, PIPE
    """
    `curl' 은 Linux/*BSD 등에서 유명한 도구입니다
    본 코드는 그래서 가급적 Linux/*BSD 시스템에서 실험하시길 권유드립니다
    """
    _cmd = "curl -s -f {0}".format(xyz)
    _try = Popen(_cmd, stdout=PIPE, shell=True)
 
    output = _try.communicate()[0].decode("utf-8").strip()
 
    return output
 
FURL = "https://kldp.org/files/Si1N.txt"
 
raw_data = _get_url(FURL)
 
fdata = raw_data.splitlines(True)
 
_key = "Optimization completed."
_offset = "Standard orientation:"
 
def start():
    lst = []
    for k in range(len(fdata)-1, -1, -1):
        if _key in fdata[k]:
            lst.append(k)
 
    return lst
 
def end(n):
    for k in range(n-1, -1, -1):
        if _offset in fdata[k]:
            return k
 
_s = start()
_e = []
 
for k in _s:
    _e.append(end(k))
 
_ss = reversed(_s)
_ee = reversed(_e)
 
for k, v in zip(_ss, _ee):
    print("\n ===> {0} {1} {2} \n".format(v+1, "~", k+1))
    print("".join(fdata[v:k+1]))
 
# 편집: VIM (Ubuntu 18.04)
# 마지막 갱신: 2021년 4월 23일

[우분투 18.04 파여폭스 나비에서 적었어요~]

댓글 첨부 파일: 
첨부파일 크기
Plain text icon 164504.txt307.87 KB

--
^고맙습니다 감사합니다_^))//

황병희의 이미지

#!/usr/bin/env python3 
# -*- coding: utf-8 -*-
 
# KLDP 164504
 
def _get_url(xyz):
    from subprocess import Popen, PIPE
    """
    `curl' 은 Linux/*BSD 등에서 유명한 도구입니다
    본 코드는 그래서 가급적 Linux/*BSD 시스템에서 실험하시길 권유드립니다
    """
    _cmd = "curl -s -f {0}".format(xyz)
    _try = Popen(_cmd, stdout=PIPE, shell=True)
 
    output = _try.communicate()[0].decode("utf-8").strip()
 
    return output
 
FURL = "https://kldp.org/files/Si1N.txt"
 
raw_data = _get_url(FURL)
 
fdata = raw_data.splitlines(True)
 
_key = "Optimization completed."
_offset = "Standard orientation:"
 
def start():
    lst = []
    for k in range(len(fdata)-1, -1, -1):
        if _key in fdata[k]:
            lst.append(k)
 
    return lst
 
def end(n):
    for k in range(n-1, -1, -1):
        if _offset in fdata[k]:
            return k
 
_s = start()
_e = []
 
for k in _s:
    _e.append(end(k))
 
_ss = reversed(_s)
_ee = reversed(_e)
 
for k, v in zip(_ss, _ee):
    print("\n ===> %s %s %s" % (v+1, "~", k+1))
    print("".join(fdata[v:v+15]))
    print(" ...")
    print(" ...")
    print(" ...")
    print("%s%s" % (fdata[k], "\n"))
 
# 편집: GNU Emacs 27.1 (Ubuntu 18.04)
# 마지막 갱신: 2021년 4월 24일

[우분투 18.04 파여폭스 나비에서 적었어유~~~]

댓글 첨부 파일: 
첨부파일 크기
Plain text icon 164504-2.txt37.15 KB

--
^고맙습니다 감사합니다_^))//

황병희의 이미지

164504-replace.py

#!/usr/bin/env python3 
# -*- coding: utf-8 -*-
 
# KLDP 164504
 
def _get_url(xyz):
    from subprocess import Popen, PIPE
    """
    `curl' 은 Linux/*BSD 등에서 유명한 도구입니다
    본 코드는 그래서 가급적 Linux/*BSD 시스템에서 실험하시길 권유드립니다
    """
    _cmd = "curl -s -f {0}".format(xyz)
    _try = Popen(_cmd, stdout=PIPE, shell=True)
 
    output = _try.communicate()[0].decode("utf-8").strip()
 
    return output
 
FURL = "https://kldp.org/files/Si1N.txt"
 
raw_data = _get_url(FURL)
 
fdata = raw_data.splitlines(True)
 
_key = "Optimization completed."
_offset = "Standard orientation:"
 
def start():
    lst = []
    for k in range(len(fdata)-1, -1, -1):
        if _key in fdata[k]:
            lst.append(k)
 
    return lst
 
def end(n):
    for k in range(n-1, -1, -1):
        if _offset in fdata[k]:
            return k
 
_s = start()
_e = []
 
for k in _s:
    _e.append(end(k))
 
_ss = reversed(_s)
_ee = reversed(_e)
 
def _replace(xyz):
    import re
 
    p = re.compile('\s+([0-9]?[0-9])\s+([0-9]?[0-9])')
    pp = p.search(xyz)
    ppp = pp.group(2)
 
    if ppp == "7":
        r = xyz.replace(ppp, "N")
    if ppp == "1":
        r = xyz.replace(ppp, "H")
    if ppp == "14":
        r = xyz.replace(ppp, "Si")
 
    return r
 
for k, v in zip(_ss, _ee):
    fdata[v+5] = _replace(fdata[v+5])
    fdata[v+6] = _replace(fdata[v+6])
    fdata[v+7] = _replace(fdata[v+7])
    fdata[v+8] = _replace(fdata[v+8])
    fdata[v+9] = _replace(fdata[v+9])
    fdata[v+10] = _replace(fdata[v+10])
    fdata[v+11] = _replace(fdata[v+11])
    print("\n ===> %s %s %s" % (v+1, "~", k+1))
    print("".join(fdata[v:v+15]))
    print(" ...")
    print(" ...")
    print(" ...")
    print("%s%s" % (fdata[k], "\n"))
 
# 편집: GNU Emacs 27.1 (Ubuntu 18.04)
# 마지막 갱신: 2021년 4월 25일

[우분투 18.04 파여폭스 나비에서 적었어유~~~]

댓글 첨부 파일: 
첨부파일 크기
Plain text icon 164504-replace.txt37.15 KB

--
^고맙습니다 감사합니다_^))//

익명 사용자의 이미지

그냥 간단하게.

복잡하게 짤 필요 있나요 ~_~

#!/usr/bin/env python3
 
import requests, periodictable, prettytable
 
def download(url):
    return requests.get(url).text
 
def parse(text):
    i_table_begin = None
    table = prettytable.PrettyTable()
    table.field_names = ('Center Number', 'Atomic Symbol', 'Atomic Type', 'Coord. X', 'Coord. Y', 'Coord. Z')
 
    for i, line in enumerate(text.splitlines()):
        if i_table_begin is None:
            if 'Standard orientation:' in line:
                i_table_begin = i + 5
                table.clear_rows()
            elif 'Optimization completed.' in line:
                yield table
 
        elif i_table_begin <= i:
            if '--' in line:
                i_table_begin = None
            else:
                CN, AN, AT, X, Y, Z = line.strip().split()
                AS = periodictable.elements[int(AN, base=10)]
                table.add_row((CN, AS, AT, X, Y, Z))
 
def main():
    for i, table in enumerate(parse(download('https://kldp.org/files/Si1N.txt')), start=1):
        print(f'{i:d}:')
        print(table)
파이썬3의 이미지

yield 로 기술을 거는 고차원의 코드!
훌륭한 코드 감사합니다^^^

[우분투 18.04 파여폭스 나비에서 적었어요~]

gksrb500의 이미지

답변 진심으로 감사드립니다.

저는 지금까지 bash 쉘 스크립트로 간단한 코딩을 해왔는데 bash 환경에서 python 실행파일을 실행시켜본 적이 없어서 어떻게 해야할지 잘 모르겠네요.

bash 쉘 스크립트로 예상했으나 파이썬으로 주실 줄 몰랐습니다 ㅠㅠ

랩실 HPC에는 보니깐 python 2.7.15, 3.6.6 이렇게 두 개가 깔려있는 것으로 보입니다.

또한 주신 파일을 저장하고 ./dfdf 해서 실행시켜봤더니

[SCAN]$ ./dfdf
: No such file or directory

라고 나옵니다.

음... 어떻게 해야할까요?

황병희의 이미지

노서치파일오어디렉토리 임시해결책 파일로 첨부했씁니다.

[우분투 18.04 파여폭스 나비에서 적었어유~]

댓글 첨부 파일: 
첨부파일 크기
Image icon Screenshot from 2021-04-24 17-07-49.png389.64 KB

--
^고맙습니다 감사합니다_^))//

황병희의 이미지

아 그리고,,,
bash 훌륭한 도구입니다. 그리고 파이썬은 더 훌륭한 도구 입니다 ^^^

요건 개인적 생각이니 너무 맘에 두지는 마시어용~~~

[우분투 18.04 파여폭스 나비에서 적었어유~~~]

--
^고맙습니다 감사합니다_^))//

gksrb500의 이미지

아 제가 컴퓨터 공학과가 아니라 코딩이나 다른 것들에 대해서 접해볼 기회가 없었습니다.

Bash 쉘 스크립트를 그동안 했던 이유는 단순하게 실험실에서 리눅스 환경에서 모든걸 진행해야 하다보니 bash 쉘 스크립트만 해봤습니다.

만약 코딩에 대해서 배울 기회가 생긴다면 당연히 파이썬을 배울 생각입니다!

윈도우에서 파이썬을 사용해본 적은 있지만 리눅스 환경에서 해본 적이 없습니다. 파이썬을 리눅스 환경에서 할 수 있는 방법만 안다면 파이썬으로 차근차근 해보려고 합니다!

황병희의 이미지

선생께서 리눅스 환경에만 익숙해지시면 파이썬으로도 충분히 기술을 걸 수 있습니다.
리눅스 환경에 익숙해지기위한 가장 적합한 배포판으로 우분투 추천합니다
그중에서도 2년마다 출시되는 LTS 를 정말 강력 추천합니다^^^

우분투는 과학계 연구원/교수분들도 많이 씁니다.

qmail 저자 번스타인교수(djb@cr.yp.to)께서도
대략 2년전 우분투 18.04 LTS 에서 뭔가를 작업하는걸 봤었어요.
===> (출처: pqc메일링)
구체적으로 양자 콤푸타 보안 산법 연구에서 우분투 18.04 LTS 를 쓰시는거 같았어요~

그리고 GNU Emacs 개발 메일링에서 주로 C언어와 관련된 패치에서 갱장히 열심히 일하시는 UCLA 콤푸타학과 교수 폴에거트(eggert@cs.ucla.edu) 이 분도 대략 1~2년 전쯤 우분투 18.04 LTS 를 쓰는걸 확인했네요...
===> (출처: GNU Emacs 개발 뉴스그룹에서)

화이팅입니다^^^

[우분투 18.04 파여폭스 나비에서 적었어요~~~]

--
^고맙습니다 감사합니다_^))//

gksrb500의 이미지

지금 보내주신 스크립트로 해본 결과 결과는 성공적으로 나온 것 같습니다.

코딩을 잠시 봤는데 이것은 제가 이 사이트에 올린 Si1N.txt.라는 파일을 가져와서 하는 것으로 생각됩니다.

이것을 /home/gksrb500/Bond/Si1N/SCAN 경로에 있는 Si1N.log라는 파일을 가져와야 합니다. (SCAN까지가 폴더 이름입니다.)

또한 이것을 출력하는 것이 아닌 메모장이나 어떤 파일 형태로 저장하고 싶은데 어떻게 해야는지 궁금합니다.

답변 정말 진심으로 감사드립니다.

황병희의 이미지

#!/usr/bin/env python3 
# -*- coding: utf-8 -*-
 
# KLDP 164504
 
def _full_path(xyz):
    from subprocess import Popen, PIPE, call
    """
    '~' 부호는 파이썬 경로명에서 잘 안먹힙니다 
    '~' 부호도 파이썬에서 먹히게끔 조치를 합니다 
    """
    call("mkdir -p {0}".format(xyz), shell=True)
    p = Popen("cd {0}; pwd -P".format(xyz), stdout=PIPE, shell=True)
    pp = p.communicate()[0].decode("utf-8").strip()
 
    return pp
 
LOG_FILE = "Si1N.log" # Si1N.txt
PATH_STRING = "~/Bond/Si1N/SCAN"
 
FPATH = "%s/%s" % (
    _full_path(PATH_STRING),
    LOG_FILE,
)
 
f = open(FPATH, "r")
raw_data = f.read(); f.close()
 
fdata = raw_data.splitlines(True)
 
_key = "Optimization completed."
_offset = "Standard orientation:"
 
def start():
    lst = []
    for k in range(len(fdata)-1, -1, -1):
        if _key in fdata[k]:
            lst.append(k)
 
    return lst
 
def end(n):
    for k in range(n-1, -1, -1):
        if _offset in fdata[k]:
            return k
 
_s = start()
_e = []
 
for k in _s:
    _e.append(end(k))
 
_ss = reversed(_s)
_ee = reversed(_e)
 
for k, v in zip(_ss, _ee):
    print("\n ===> %s %s %s" % (v+1, "~", k+1))
    print("".join(fdata[v:v+15]))
    print(" ...")
    print(" ...")
    print(" ...")
    print("%s%s" % (fdata[k], "\n"))
 
# 편집: GNU Emacs 27.1 (Ubuntu 18.04)
# 마지막 갱신: 2021년 4월 24일

[우분투 18.04 파여폭스 나비에서 적었어욧~~~]

댓글 첨부 파일: 
첨부파일 크기
Image icon Screenshot from 2021-04-24 21-54-51.png397.74 KB
Plain text icon 164504-3.txt36.62 KB

--
^고맙습니다 감사합니다_^))//

ymir의 이미지

그냥 아이디어만 보세요.
csplit 을 써서 Input orientation: 을 기준으로 개별 파일로 나눈 후에..
Optimiation completed 가 들어 있는 파일만 처리한 겁니다.

$ ls -al
total 1032
drwxr-xr-x 2 ymir ymir 135168  424 18:53 .
drwxrwxr-x 7 ymir ymir   4096  325  2020 ..
-rw------- 1 ymir ymir 910182  424 18:19 Si1N.txt
$ csplit Si1N.txt '/Input orientation:/' '{*}'
7763
...
8765
$ ls
Si1N.txt  xx02  xx05  xx08  xx11  xx14  xx17  xx20  xx23  xx26  xx29  xx32  xx35  xx38  xx41  xx44  xx47  xx50  xx53  xx56  xx59  xx62  xx65  xx68  xx71
xx00      xx03  xx06  xx09  xx12  xx15  xx18  xx21  xx24  xx27  xx30  xx33  xx36  xx39  xx42  xx45  xx48  xx51  xx54  xx57  xx60  xx63  xx66  xx69  xx72
xx01      xx04  xx07  xx10  xx13  xx16  xx19  xx22  xx25  xx28  xx31  xx34  xx37  xx40  xx43  xx46  xx49  xx52  xx55  xx58  xx61  xx64  xx67  xx70
$ grep 'Optimization completed' Si1N.txt | wc -l
34
$ grep 'Optimization completed' xx?? | wc -l
34
$ grep 'Optimization completed' xx?? | cut -d: -f1 | while read -r file; do grep -A12 'Standard orientation:' $file > completed_$file; done
$ ls completed_xx*
completed_xx10  completed_xx19  completed_xx27  completed_xx35  completed_xx43  completed_xx51  completed_xx56  completed_xx61  completed_xx69
completed_xx13  completed_xx21  completed_xx29  completed_xx37  completed_xx45  completed_xx53  completed_xx57  completed_xx63  completed_xx71
completed_xx15  completed_xx23  completed_xx31  completed_xx39  completed_xx47  completed_xx54  completed_xx58  completed_xx65
completed_xx17  completed_xx25  completed_xx33  completed_xx41  completed_xx49  completed_xx55  completed_xx59  completed_xx67
$ for file in completed_xx??; do cat $file | sed 's/        7\b/        N/;s/        1\b/        H/;s/       14\b/       Si/' > ${file/completed/out}; done
$ ls out_xx*
out_xx10  out_xx15  out_xx19  out_xx23  out_xx27  out_xx31  out_xx35  out_xx39  out_xx43  out_xx47  out_xx51  out_xx54  out_xx56  out_xx58  out_xx61  out_xx65  out_xx69
out_xx13  out_xx17  out_xx21  out_xx25  out_xx29  out_xx33  out_xx37  out_xx41  out_xx45  out_xx49  out_xx53  out_xx55  out_xx57  out_xx59  out_xx63  out_xx67  out_xx71
$ cat out_xx10
                         Standard orientation:
 ---------------------------------------------------------------------
 Center     Atomic      Atomic             Coordinates (Angstroms)
 Number     Number       Type             X           Y           Z
 ---------------------------------------------------------------------
      1          N           0       -0.052963    1.214246   -0.000000
      2          H           0        0.484249    1.521097    0.814525
      3          H           0        0.484249    1.521097   -0.814525
      4         Si           0       -0.052963   -0.631573    0.000000
      5          H           0       -0.634200   -1.219249    1.239574
      6          H           0       -0.634200   -1.219249   -1.239574
      7          H           0        1.412117   -0.261395    0.000000
 ---------------------------------------------------------------------

되면 한다! / feel no sorrow, feel no pain, feel no hurt, there's nothing gained.. only love will then remain.. 『 Mizz 』

gksrb500의 이미지

completed_xx?? 헝태로 나온 것들을 H_Si_N_1 H_Si_N_2 처럼 오름차순으로 재정리하고 싶습니다.

주신 코드로 해본결과 completed_xx10, completed_xx18 이렇게 뜨문뜨문 생겼습니다.

H_Si_N 은 ${FOLDER_NAME}으로 이미 정의가 되어있습니다. 따라서 뒤에 있는 숫자만 변수화하여 뒤에 붙이고 싶습니다.

ymir의 이미지

$ i=0
$ for file in completed_xx*; do cp $file H_Si_N_$i; let i++; done

되면 한다! / feel no sorrow, feel no pain, feel no hurt, there's nothing gained.. only love will then remain.. 『 Mizz 』

gksrb500의 이미지

정말 감사드립니다.

csplit으로 생긴 xx파일들이 xx195같이 3자리수가 넘어가는 경우도 있습니다. 그래서 물음표가 두 개 있는 부분을 ???를 해줬더니 이번엔 기존에 잘 되던 xx뒤에 두자리수가 있는 경우는 인식을 못하는 것 같습니다. 어떻게 해야할까요... 제가 스크립트와 폴더들을 첨부하겠습니다. xyz_search가 스크립트입니다.

댓글 첨부 파일: 
첨부파일 크기
Package icon Angle.zip6.47 MB
ymir의 이미지

되면 한다! / feel no sorrow, feel no pain, feel no hurt, there's nothing gained.. only love will then remain.. 『 Mizz 』

파이썬3의 이미지

항상 느끼지만 ymir 님이 쉘 도구로 기술을 걸때마다 카타르시스가 느껴집니다.
늘 훌륭하며 소중한 코드에 감사드립니다!!!

[우분투 18.04 파여폭스 나비에서 적었어요~]

gksrb500의 이미지

선배님들께서 주신 관심 덕분에 성공적으로 코딩을 완료할 수 있었습니다.

진심으로 다시 한번 감사드립니다.

익명 사용자의 이미지

bash$ sed -En '
/^\s*Standard orientation:\s*$/{
    h; :X n; /^\s*Standard orientation:\s*$/{h; bX}
    /^\s*Optimization completed\.\s*$/{ g;
        s/(Standard basis: [^\n]+)/\1\a/; s/\a.*/\n\n/;
        s/^(\s*[0-9]+\s+)7 /\1N/Mg; 
        s/^(\s*[0-9]+\s+)1 /\1H/Mg; 
        s/^(\s*[0-9]+\s+)14 /\1Si/Mg; 
        p; bX
    }; H; bX 
}' Si1N.txt

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.