:
다음은 샘플 스크립트입니다.
Cobalt:bin donald$ ./karaf
__ __ ____
///_/____ __________ _/ __/
/,</__ `/ ___/ __ `/ /_
//| |/ /_/////_//__/
/_/ |_|\__,_/_/ \__,_/_/
Apache Karaf (3.0.2)
Hit '<tab>' for a list of available commands
and '[cmd] --help' for help on a specific command.
Hit '<ctrl-d>' or type 'system:shutdown' or 'logout' to shutdown Karaf.
[email protected]()> shell:exec pwd
/Users/donald/apache-karaf-3.0.2
[email protected]()> shell:exec ls
LICENSE
NOTICE
README
RELEASE-NOTES
bin
data
demos
deploy
etc
instances
lib
lock
system
test.script
[email protected]()> shell:source test.script
START LEVEL 100 , List Threshold: 0
ID | State | Lvl | Version | Name
-----------------------------------------------------------------------------------------------------------
0 | Active | 0 | 4.2.1 | System Bundle
1 | Active | 5 | 2.2.0 | OPS4J Pax Url - aether:
2 | Active | 5 | 2.2.0 | OPS4J Pax Url - wrap:
3 | Active | 8 | 1.7.4 | OPS4J Pax Logging - API
4 | Active | 8 | 1.7.4 | OPS4J Pax Logging - Service
5 | Active | 10 | 3.0.2 | Apache Karaf :: Service :: Guard
6 | Active | 10 | 1.8.0 | Apache Felix Configuration Admin Service
Hello world 1
Hello world 2
Hello world 3
[email protected]()>
가 아주 좋은 예, 나는 karaf를 시작한 사용자에게 test.script을 chown하지에 있었나요 소스, 그리고 : t에서 "번들 목록"명령 그는 스크립트의 첫 번째 줄은 JBoss Fuse ("6.1.0.rehat-379")의 "osgi : list"이지만 그 외에는 속임수입니다! 고마워. –