예전글에서 프로젝트 리비전을 분할관리 해야할 것 같아서 다시 한번 시도를 해봤는데 아래와 같은 내용이 있었다.

USAGE:
cvs2svn [OPTIONS]... [-s SVN-REPOS-PATH|--dumpfile=PATH|--dry-run] CVS-REPOS-PATH
cvs2svn [OPTIONS]... --options=PATH
CVS-REPOS-PATH The filesystem path of the part of the CVS repository that you want to convert. It is not possible to convert a CVS repository to which you only have remote access; see the FAQ for details. This doesn't have to be the top level directory of a CVS repository; it can point at a project within a repository, in which case only that project will be converted. This path or one of its parent directories has to contain a subdirectory called CVSROOT (though the CVSROOT directory can be empty).
Configuration via options file
--options=PATH Read the conversion options from the specified file. See section options file method for more information.
Output options
-s PATH
--svnrepos PATH
Write the output of the conversion into a Subversion repository located at PATH. This option causes a new Subversion repository to be created at PATH unless the --existing-svnrepos option is also used.

[링크 : http://cvs2svn.tigris.org/cvs2svn.html]



예를들어
/home/cvs
|-- CVSROOT
|-- Project1
|-- Project2
`-- Project3
이런구조의 cvs repository라면,

$ cvs2svn --svnrepos /home/svn/ --encoding=cp949 /home/cvs/
으로 할경우, 리비전이 전부 하나로 묶이고, 프로젝트가 분리되지 않는다.

$ cvs2svn --svnrepos /home/svn/Project1 --encoding=cp949 /home/cvs/Project1
$ cvs2svn --svnrepos /home/svn/Project2 --encoding=cp949 /home/cvs/Project2
$ cvs2svn --svnrepos /home/svn/Project3 --encoding=cp949 /home/cvs/Project3
이렇게 하면 개별 프로젝트로 repository가 생성이 된다.
(부가적으로 revision이 단순해져서 변환도 상대적으로 빨라지는 듯하다)

2009/05/10 - [프로그램 사용/CVS / SVN / GIT] - cvs2svn 사용방법

'프로그램 사용 > Version Control' 카테고리의 다른 글

visualSVN  (0) 2010.09.09
TortoiseSVN tag/branch = copy  (2) 2010.04.30
svn / svnadmin 도움말  (0) 2010.04.23
CVS / SVN 장단점, 차이점 비교  (6) 2010.04.07
GIT는 리눅스에서 받으시는걸 추천합니다.  (0) 2010.03.18
Posted by 구차니
자세히 보면 티가 나지만, 어떤녀석은 URL 이고 어떤 녀석은 PATH이다.
일단 URL에서 파일 경로일 경우에는 file:/// 이라고 / 개 3개가 들어가야 한다.

$ svnadmin create [repository direcotry name]
$ svn checkout file:///[absolute path] [name of repository which will create]

머.. 일단 콘솔에서는 이렇게 초기화 하고 만들면 될 듯.

$ svnadmin help
general usage: svnadmin SUBCOMMAND REPOS_PATH  [ARGS & OPTIONS ...]
Type 'svnadmin help <subcommand>' for help on a specific subcommand.

Available subcommands:
   crashtest
   create
   deltify
   dump
   help (?, h)
   hotcopy
   list-dblogs
   list-unused-dblogs
   load
   lslocks
   lstxns
   recover
   rmlocks
   rmtxns
   setlog
   verify

$ svnadmin help create
create: usage: svnadmin create REPOS_PATH

Create a new, empty repository at REPOS_PATH.

Valid options:
  --bdb-txn-nosync         : disable fsync at transaction commit [Berkeley DB]
  --bdb-log-keep           : disable automatic log file removal [Berkeley DB]
  --config-dir arg         : read user configuration files from directory ARG
  --fs-type arg            : type of repository: 'fsfs' (default) or 'bdb'

$ svn help
usage: svn <subcommand> [options] [args]
Subversion command-line client, version 1.3.2.
Type 'svn help <subcommand>' for help on a specific subcommand.

Most subcommands take file and/or directory arguments, recursing
on the directories.  If no arguments are supplied to such a
command, it recurses on the current directory (inclusive) by default.

Available subcommands:
   add
   blame (praise, annotate, ann)
   cat
   checkout (co)
   cleanup
   commit (ci)
   copy (cp)
   delete (del, remove, rm)
   diff (di)
   export
   help (?, h)
   import
   info
   list (ls)
   lock
   log
   merge
   mkdir
   move (mv, rename, ren)
   propdel (pdel, pd)
   propedit (pedit, pe)
   propget (pget, pg)
   proplist (plist, pl)
   propset (pset, ps)
   resolved
   revert
   status (stat, st)
   switch (sw)
   unlock
   update (up)

Subversion is a tool for version control.
For additional information, see http://subversion.tigris.org/

$ svn help list
list (ls): List directory entries in the repository.
usage: list [TARGET[@REV]...]

  List each TARGET file and the contents of each TARGET directory as
  they exist in the repository.  If TARGET is a working copy path, the
  corresponding repository URL will be used. If specified, REV determines
  in which revision the target is first looked up.

  The default TARGET is '.', meaning the repository URL of the current
  working directory.

  With --verbose, the following fields will be shown for each item:

    Revision number of the last commit
    Author of the last commit
    If locked, the letter 'O'.  (Use 'svn info URL' to see details)
    Size (in bytes)
    Date and time of the last commit

Valid options:
  -r [--revision] arg      : ARG (some commands also take ARG1:ARG2 range)
                             A revision argument can be one of:
                                NUMBER       revision number
                                "{" DATE "}" revision at start of the date
                                "HEAD"       latest in repository
                                "BASE"       base rev of item's working copy
                                "COMMITTED"  last commit at or before BASE
                                "PREV"       revision just before COMMITTED
  -v [--verbose]           : print extra information
  -R [--recursive]         : descend recursively
  --incremental            : give output suitable for concatenation
  --xml                    : output in XML
  --username arg           : specify a username ARG
  --password arg           : specify a password ARG
  --no-auth-cache          : do not cache authentication tokens
  --non-interactive        : do no interactive prompting
  --config-dir arg         : read user configuration files from directory ARG

$ svn help checkout
checkout (co): Check out a working copy from a repository.
usage: checkout URL[@REV]... [PATH]

  If specified, REV determines in which revision the URL is first
  looked up.

  If PATH is omitted, the basename of the URL will be used as
  the destination. If multiple URLs are given each will be checked
  out into a sub-directory of PATH, with the name of the sub-directory
  being the basename of the URL.

Valid options:
  -r [--revision] arg      : ARG (some commands also take ARG1:ARG2 range)
                             A revision argument can be one of:
                                NUMBER       revision number
                                "{" DATE "}" revision at start of the date
                                "HEAD"       latest in repository
                                "BASE"       base rev of item's working copy
                                "COMMITTED"  last commit at or before BASE
                                "PREV"       revision just before COMMITTED
  -q [--quiet]             : print as little as possible
  -N [--non-recursive]     : operate on single directory only
  --username arg           : specify a username ARG
  --password arg           : specify a password ARG
  --no-auth-cache          : do not cache authentication tokens
  --non-interactive        : do no interactive prompting
  --config-dir arg         : read user configuration files from directory ARG
  --ignore-externals       : ignore externals definitions


'프로그램 사용 > Version Control' 카테고리의 다른 글

TortoiseSVN tag/branch = copy  (2) 2010.04.30
cvs2svn 사용방법 2  (0) 2010.04.23
CVS / SVN 장단점, 차이점 비교  (6) 2010.04.07
GIT는 리눅스에서 받으시는걸 추천합니다.  (0) 2010.03.18
TortoiseGIT  (0) 2010.03.18
Posted by 구차니
expat도 SAX의 일종이라고 할 수 있을지는 모르겠지만,
방식측면에서는 event-driven 이니 SAX는 맞는것 같다.

아무튼, DOM 구조가 없으니 navigation은 힘든편.

SAX (Simple API for XML) is a serial access parser API for XML. SAX provides a mechanism for reading data from an XML document. It is a popular alternative to the Document Object Model (DOM).

[링크 : http://en.wikipedia.org/wiki/Simple_API_for_XML]

DOM vs SAX 파서

두 가지 유형의 XML 문서 파서가 있다. 이들은 XML 문서에 액세스하는 방식부터 다르다:

  • Document Object Model (DOM). XML 문서로의 랜덤 액세스(random access)에 사용된다. DOM의 장점은 메모리 안에 문서의 전체 모델을 갖고 있다는 점이다. 이는 모든 XML 엘리먼트에 어떤 순서로든지 액세스가 가능하다는 것을 의미한다. 하지만 큰 문서의 경우 둔해 질 수 있다. 메모리에서 실행시키지 않으면 시스템이 한계에 다다를 때 퍼포먼스가 느려진다.
  • Simple API for XML (SAX). 순차적 액세스(sequential access)에 사용된다. SAX의 장점은 문서의 한 부분이 메모리에서 사용될 수 있기 때문에 보다 큰 문서를 핸들할 수 있다는 점이다. SAX의 단점은 엘리먼트를 순서대로 처리해야 하며 한번에 볼 수 있는 문서 부분도 작다. SAX를 이용하여 문서를 파싱할 때 XML 부분을 저장할 수 있다.

[링크 : http://www.ibm.com/developerworks/kr/library/j-xmljava/]

Simple API for XML (SAX) 이벤트 중심 API이다. XML 마크업의 다른 부분들(시작과 끝 태그, 텍스트, 엔터티)에서 실행된 특정 이벤트용 핸들러 코드를 등록한다. 이 파서는 인풋 XML에 기반하여 이러한 이벤트들의 스트림을 보내면, 핸들러 코드는 이를 처리한다.

[링크 : http://www.ibm.com/developerworks/kr/xml/standards/x-saxspec.html]

SAX is the Simple API for XML, originally a Java-only API. SAX was the first widely adopted API for XML in Java, and is a “de facto” standard.

[링크 : http://www.saxproject.org/] SAX 공식


Posted by 구차니
위는 태국어
아래는 히브리어


태국어가 획이 많을뿐, 느낌은 비슷하다?

이스라엘에서 국어로서 히브리어/아랍어를 사용하며,
아랍어와 같이 오른쪽에서 왼쪽으로 글을 쓴다.
유니코드 상에서는 0x0590 ~ 0x05FF 영역이며, 0xFB1E ~ 0xFB4F 영역에도 존재한다. (뒤에 영역은 머지?)
모양을 보니, 아랍어와 같이 첨자가 붙어 조합을 해야할 것으로 보인다.


[링크 : http://enc.daum.net/dic100/contents.do?query1=10XXX32946] 타이어
[링크 : http://enc.daum.net/dic100/contents.do?query1=10XXX12664] 히브리어
[링크 : http://ko.wikipedia.org/wiki/타이]
[링크 : http://ko.wikipedia.org/wiki/이스라엘]
[링크 : http://www.hope-ind.com/Elpis/Elpis_home.htm]


아무튼 계통이 전혀 다른 언어임에도 불구하고 유사해 보이는건.. 특이한 경우인가?
 언어 계통따이까다이어족
 깜따이어파
  Be-Tai
   Tai-Sek
    타이어군
     남 서타이
      동타이
       Chiang Saeng
        타이어
 아프리카아시아어족
 셈어파
  서셈어군
   중 부셈어
    북서셈어
     가나안어
      히 브리어


Posted by 구차니
iconv() 함수에서
변환결과로 나와야 하는 방법이 unicode일 경우에는 (일단 다른건 안해봤으니 -ㅁ-?)
(strlen(inbuf) + 2) * 2 가 된다.

size_t iconv(iconv_t cd,
                     char **inbuf, size_t *inbytesleft,
                     char **outbuf, size_t *outbytesleft);

예를 들어 UTF-8을 UNICODE로 변환시에는
UTF-8 문자열 특성상, stelen(utf8str) == 100 일 경우
유니코드(2바이트) 스트링은 최소 25에서 최대 100 까지 변환이 된다.

그리고 iconv 특성상 처음에 2바이트 BOM(Byte Order Mark)을 붙이므로
실질적으로 변환을 위해 필요로 하는 outbuf의 길이는
(strlen(inbuf) + 2) * 2 가 된다.

원래대로라면
(strlen(inbuf) + 1) * 2 + 2 이고
+1 은 '\0'
+2 는 Unicode BOM(0xFEFF in big endian)이다.

[링크 : http://mwultong.blogspot.com/2006/05/qna-unicode-bom-byte-order-mark.html]


덧 : UTF-8로 인코딩된 아랍어의 경우, 조합은 별도로 해주어야 한다.
iconv()가 UNICODE로 변환은 해주지만, 그렇다고 해서 조합까지 해주지는 않는다.
Posted by 구차니
물론 난 중간에 끼인 세대로서
일단은 취업을 했고, 그렇다고 해서 지금의 80년 중후반 세대처럼 죽네사네 하지도 않았고,
그렇다고 해서 90학번 이전 세대 처럼 몇백주고 pc 학원 다녀서 전산실 취업하고 띵까띵까 노는 세대도 아니고


솔찍히 환경적인 면이라던가, 배워야 하는 정보의 양에서
현재의 아이들은 과거의 어른이 되어버린 아이들보다 엄청나게 많다.
사회/기술은 발전해가고, 그로 인해서 점점 후대에 태어난 사람은
배워야 할건 많고, 기술의 발전속도는 더더욱 빨라지는 상황에서
인간이 받아들일수 있는 정보의 양은 한계가 있고, 습득할수 있는 양의 한계는 더욱 좁다.

90이전 학번들의
"우리때는 정보도 없고, 혼자서 맨땅에 헤딩해야 했어. 그에 비하면 너네는 인터넷도 있고 좋잖아~"
라는 드립을 듣고 있으면, 수긍보다는 짜증이 밀려온다.
"아 예. 그러셨쎄요? 맨땅에 헤딩할 시간도 있었고 좋으셨겠어요~"
라고 밖에 카운터를 날릴수가 없으니 답답하기만 하다.

천천히 기술이 개발하던 시기에 헤딩도 해서 답이 나올수준의 기술들.
그에 비하면 배우는 입장에 그들의 수준을 기준으로 이야기 하는 '보통'이라는 수준의 높이.
진심으로 묻고 싶다.

당신들이 c언어 기본도 하나도 모르는 상태에서 지금의 아이들 처럼 시작해서
어느정도 높이 까지 올라갈수 있겠는가? 지금의 88만원 세대들에게 70년대 헝그리 정신만으로
얼마나 기술을 습득하고 단기간에 배울수 있겠는가?


지금 아이들도 충분히 빡시다.
쓰지도 않을 쓸데없는 정보들에 묻혀
그리고 앞에 사람들이 배워왔던 그리고 장시간에 축적해온 기술들을 단시간에 흡수해야 하는데
그정도로도 충분히 이미 힘들어하는 아이들에게 얼마나 더 짐을 지으고 싶어 하는건가?


물론, 나역시 한때는 환경이 지랄맞아도
그 사람의 생각이 옳곧기만 하다면, 살인자 마을에서 성자가 날수도 있고,
환경이 나쁘다고 해서 나쁜 아이가 된건 그 아이의 잘못이라고 생각했다.

하지만, 돌이켜 보건데 내가 있었던 환경들이 나쁜건 아니었고
정말 진심으로 부모님들의 사랑을 받으면서 그때는 싫었던 것들이
지극히 정상적이고 소소한 일상이었고, 그 속에서 사랑을 듬뿍 받으면서 자랐다는걸 이제야 꺠달았을때
나의 그러한 생각들은, 내가 그만큼 미숙했기 때문이었기에 나온 그릇된 판단이었기 때문이다.



요약 :
당신들은 기술발전도 느린 시절부터 차곡차곡 배워왔지만,
지금의 아이들은 만렙과 싸워야 하는 1렙 초보이고, 당신들의 수준에 이르기 위해 필요로 하는 시간이
당신들 보다 상대적으로 적고, 배워야 할 것은 많다.

캠퍼스의 낭만?
웃기지도/ 좆까지도 말라고 그래라. 지금의 캠퍼스에 낭만이 있는가?
이미 경쟁으로 인해 피로 얼룩진 전장일 뿐이다.

당신들의 게으름으로 인해 다음세대들이 피를 더 흘리는 것을
왜 나약하다고 떠넘기기만 하는가?

[링크 : http://www.devpia.com/MAEUL/Contents/Detail.aspx?BoardID=69&MAEULNO=28&no=13894&page=2] 허약한
[링크 : http://www.devpia.com/MAEUL/Contents/Detail.aspx?BoardID=69&MAEULNO=28&no=13909&page=1] 나약해?

'개소리 왈왈 > 직딩의 비애' 카테고리의 다른 글

..............  (10) 2010.05.25
2009년 SW 기술자 노임 단가  (2) 2010.05.18
딱고 조이고 기름치고!  (0) 2010.04.21
출근일기 - 20100406  (6) 2010.04.06
주간회의 == 인민재판?  (0) 2010.04.06
Posted by 구차니
Programming/C Win32 MFC2010. 4. 22. 14:28

#include "stdio.h"

int main(int argc, char *argv[])
{
	int x = 1;
	printf("%d %d %d\n", ++x, x, x++);
	return 0;
}

You're running into two issues:

1. Undefined behavior -- you are attempting to modify the value of an
object more than once between sequence points, and the Standard imposes
no requirement on how to handle that behavior. Basically, any
expression of the forms:

i = i++;
j = k++ * k++;
foo(i,i++,--i);

invoke undefined behavior. Read up on the semantics of the "++" and
"--" operators in an *authoritative* reference (the Standard would
obviously be one, but also K&R2 or H&S5); they don't work the way most
people think they should.

2. Order of evaluation -- AFAIK, there's no requirement that
expressions in a function parameter list be evaluated in any particular
order. At first blush, it *looks* like the arguments were evaluated
from right to left (if x = 1, then x++ evaluates to 1, with the side
effect that x == 2, and ++x evaluates to 3, with the side effect that x
== 3), but given that you've invoked undefined behavior the actual
reason may be something else entirely.

[링크 : http://bytes.com/topic/c/answers/222558-operation-x-may-undefined]

위의 소스를 gcc -Wall 옵션을 주고 컴파일 할 경우에
$ gcc -Wall cc_test.c
cc_test.c: In function ‘main’:
cc_test.c:6: warning: operation on ‘x’ may be undefined
cc_test.c:6: warning: operation on ‘x’ may be undefined
이런 경고가 발생한다.

분명 x는 변수인데, 그에 대한 operation이 정의되지 않았다는게 무슨 말인지 모르겠지만,
아무튼 실행을 하면
$ ./a.out
3 3 1
요런 희한한 결과가 나온다.

아무튼, calling convention과도 연관이 있어 보이는데,
c언어 특성상 right-left 로 push 하므로(가장 위에는 왼쪽 값이 오도록)
가장 먼저들어가는, 오른쪽 x++ 은 1이 들어가고
1을 더해준다음, 다음 명령어를 수행하면서(++x) 한번에 2가 증가하게 되고
그럼으로 인해 x, ++x 순으로 3이 들어가는게 아닐까 생각된다.

아니면 말구?

[링크 : http://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html]


winXP SP3 32bit / VC++ 6 에서 해본 결과
 2 1 1


linux / gcc 결과
 3 3 1


objdump를 소스와 함께 디스어셈블 하기 위해서는
gcc -g 옵션으로 디버깅 정보를 주어야 한다.
[링크 : http://wikidocs.net/mybook/1473]


솔찍히 어셈을 몰라서 모르겠다 ㅋㅋ
결론 : 한줄에 ++나 -- 연산자를 중복으로 사용하지 말자.
Posted by 구차니
프로그램 사용/VLC2010. 4. 22. 11:06
http://192.168.10.94:8080/?control=pause

현재 사용중인 PC의 ip가 192.168.10.94 이고, VLC 에서 웹 인터페이스를 켜놨을 경우
위와 같이 URL을 입력하면 플레이 중인 동영상이 일시정지 된다.
pause는 토글 방식으로, 한번 보내면 멈추고, 다시 보내면 재생된다.

위는 dreambox에서 PC의 VLC로 원격명령을 날리는 부분을, wireshark로 캡쳐한 화면

2010/04/21 - [프로그램 사용/VLC] - VLC를 웹 쿼리로 제어하기 - VLC web control

'프로그램 사용 > VLC' 카테고리의 다른 글

VLC - V4L2 modules  (0) 2010.07.03
VLC 1.1.0 Luggage  (0) 2010.07.03
VLC를 웹 쿼리로 제어하기 - VLC web control  (0) 2010.04.21
x264 와 h264의 관계?  (0) 2010.04.15
VLC nightly build  (0) 2010.04.13
Posted by 구차니
프로그램 사용/VLC2010. 4. 21. 15:08
VLC 에는 web interface 라는 넘이 있는데,
이녀석을 원격지에서 http query를 통해 제어가 가능하다.

윈도우에서 기본설치시
C:\Program Files\VideoLAN\VLC\http\requests 경로에 존재하는 파일을 읽어보면 될 듯 하다.

웹에서 접속시에는
http://localhost:8080/requests/filename.xml?query
식으로 하면된다.

아래는 readme.txt 파일
$Id$

This file describes commands available through the requests/ file:

Lines starting with < describe what the page sends back
Lines starting with > describe what you can send to the page

All parameters need to be URL encoded.
Examples:
 # -> %23
 % -> %25
 + -> %2B
 space -> +
 ...

status.xml:
===========
< Get VLC status information, current item info and meta.

> add <mrl> to playlist and start playback:
  ?command=in_play&input=<mrl>

> add <mrl> to playlist:
  ?command=in_enqueue&input=<mrl>

> play playlist item <id>:
  ?command=pl_play&id=<id>

> toggle pause. If current state was 'stop', play item <id>:
  ?command=pl_pause&id=<id>

> stop playback:
  ?command=pl_stop

> jump to next item:
  ?command=pl_next

> jump to previous item:
  ?command=pl_previous

> delete item <id> from playlist:
  ?command=pl_delete&id=<id>

> empty playlist:
  ?command=pl_empty

> sort playlist using sort mode <val> and order <id>:
  ?command=pl_sort&id=<id>&val=<val>
  If id=0 then items will be sorted in normal order, if id=1 they will be
  sorted in reverse order
  A non exhaustive list of sort modes:
    0 Id
    1 Name
    3 Author
    5 Random
    7 Track number

> toggle random playback:
  ?command=pl_random

> toggle loop:
  ?command=pl_loop

> toggle repeat:
  ?command=pl_repeat

> toggle enable service discovery module <val>:
  ?command=pl_sd&val=<val>
  Typical values are:
    sap
    shoutcast
    podcast
    hal

> toggle fullscreen:
  ?command=fullscreen

> set volume level to <val> (can be absolute integer, percent or +/- relative value):
  ?command=volume&val=<val>
  Allowed values are of the form:
    +<int>, -<int>, <int> or <int>%

> seek to <val>:
  ?command=seek&val=<val>
  Allowed values are of the form:
    [+ or -][<int><H or h>:][<int><M or m or '>:][<int><nothing or S or s or ">]
    or [+ or -]<int>%
    (value between [ ] are optional, value between < > are mandatory)
  examples:
    1000 -> seek to the 1000th second
    +1H:2M -> seek 1 hour and 2 minutes forward
    -10% -> seek 10% back

playlist.xml:
=============
< get the full playlist tree

browse.xml:
===========
< ?dir=<dir>
> get <dir>'s filelist

vlm.xml:
========
< get the full list of VLM elements

vlm_cmd.xml:
============
< execute VLM command <cmd>
  ?command=<cmd>
> get the error message from <cmd>



[링크 : http://forum.videolan.org/viewtopic.php?f=16&t=45842]

2009/12/08 - [프로그램 사용/VLC] - VLC 웹 인터페이스 원격지에서 안될경우
2009/11/24 - [프로그램 사용/VLC] - VLC web interface(웹 인터페이스)
Posted by 구차니
개소리 왈왈/영화2010. 4. 21. 11:09





내가 개띠이긴 하지만..
애인이 보내오는 애인네 고냥이를 보면..
고양이를 기르고 싶어진다.

'개소리 왈왈 > 영화' 카테고리의 다른 글

아이언맨 2  (8) 2010.05.02
광화문 / 경복궁  (4) 2010.04.25
free for what?  (0) 2010.04.02
end of D+848  (0) 2010.03.29
그린존 (Grren zone, 2010)  (4) 2010.03.28
Posted by 구차니