我想拥有与此karaf命令相同的功能:
feature:add-repo mvn:org.apache.cxf.karaf/apache-cxf/3.3.1/xml/features
更大的前景是,我希望能够进行干净的karaf安装,将.kar文件复制到deploy文件夹,然后下载并安装feature.xml中定义的所有功能。
当前,我有一个feature.xml列出了所需的功能,但是cxf不在预配置的存储库中。为了进行测试,我已将存储库添加到org.apache.karaf.features.cfg
。
我尝试使用<library>
元素,但这似乎没有实现。
(我的工作基于karaf-jpa-example。)
谢谢
答案 0 :(得分:1)
如果我明白了您要尝试做的事情,这应该可以解决问题:
Sub newestFile()
Dim FileSystem As Object ' Needed to get file properties
Set FileSystem = CreateObject("Scripting.FileSystemObject")
Dim MostRecentDate As Date
Dim MostRecentFile As String
Directory = "c:\Directory1\"
FileSpec = "*.txt" '<-- can be "*.xls*" or whatever criteria needed
MyFile = ""
'Loop through text files in Directory finding the most current file
MyFile = Dir(Directory & FileSpec) 'Get first file name in directory
Do While MyFile <> ""
If MostRecentDate < FileSystem.GetFile(Directory & MyFile).DateLastModified Then
MostRecentDate = FileSystem.GetFile(Directory & MyFile).DateLastModified
MostRecentFile = MyFile
End If
MyFile = Dir 'Get next file matching criteria
Loop
set ws = Sheets("Events")
ws.cells(2,7).value = MostRecentFile
ws.cells(2,8).value = MostRecentDate
End Sub
有关丰富的示例,请参见CXF Karaf feature project。