Run Clojure Script with External Dependencies without leiningen
The normal way of deploy clojure files is using leiningen. But if we have no leiningen, or the script is small and unnecessary to pack as a leiningen project, we can build a "bare" clojure script in the following way.
Get the dependency jar files, 2 options:
i. download the jar file directly;
i. if the dependency project provide the dependency as leiningen dependency items in porject.clj (for example, "[org.clojure/data.json "0.2.3"]" in data.json), you can build the leiningen project following Parse Sonarqube Data via Web API in Clojure , then copy the denpendency jar files from the ~/.m2/repository folder;
Build srcipt: get-sonar-data.clj
(require '[clojure.data.json :as json])
(def url "http://10.0.2.74:9000/api/resources?resource=ESB:com.boco.esb.analysismgr.service.impl&metrics=classes")
(def data (json/read-str (slurp url)))
(println ((first data) "name"))
(println ((first ((first data) "msr")) "val"))
Run script: java -cp './*:.' clojure.main get-sonar-data.clj
Run Clojure Script with External Dependencies without leiningen的更多相关文章
- VC中Source Files, Header Files, Resource Files,External Dependencies的区别
VC中Source Files, Header Files, Resource Files,External Dependencies的区别 区别: Source Files 放源文件(.c..cpp ...
- npm link & run npm script
npm link & run npm script https://blog.csdn.net/juhaotian/article/details/78672390 npm link命令可以将 ...
- Run bash script as daemon
linux - Run bash script as daemon - Stack Overflow https://stackoverflow.com/questions/19233529/run- ...
- The fileSyncDll.ps1 is not digitally signed. You cannot run this script on the current system.
https://www.opentechguides.com/how-to/article/powershell/105/powershel-security-error.html Unblockin ...
- C语言&C++ 中External dependencies
参考:https://blog.csdn.net/yyyzlf/article/details/4419593 External Dependencies是说你没有把这个文件加入到这个工程中,但是 ...
- 建立Clojure开发环境-使用IDEA和Leiningen
OS: Mac OS X 10.10 IDEA 14.0.2 Community Edition 安装Leiningen 按照http://leiningen.org/的指南安装lein 阅读Lein ...
- csharp:SMO run sql script
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; usin ...
- Clojure 开发环境 light table 和 Leiningen 安装指引
1 首先下载 Light table 然后 解压到到一文件夹.目录中千万不能有空格 下载地址 http://www.lighttable.com/ 2下载构建工具 下载地址 http://leinin ...
- Run QTP script wiht host in HPQC
随机推荐
- layui table 使用table放输入框时控制每列的宽度
<table class="layui-table" lay-filter="demo"> <colgroup> <%--设置每列 ...
- 使用IDEA配置Maven
IDEA中配置Maven File --> settings 推荐配置:设置maven在不联网的情况下使用本地插件 一般使用maven为我们提供好的骨架时,是需要联网的,配置这个,可以在没有网络 ...
- centos 安装es
第一步:必须要有jre支持 elasticsearch是用Java实现的,跑elasticsearch必须要有jre支持,所以必须先安装jre 第二步:下载elasticsearch 进入官方下载 h ...
- CG-CTF Our 16bit Games
一.放到xp上面跑,发现是一个图形界面的飞机游戏...估计是分数到达多少,然后就可以输出flag. 打开ida,一脸懵逼,主要这玩意16位,我直接静态调试了 发现很多汇编代码,有点懵逼,在最下方的地方 ...
- C语言:获取汉字的编码
#include <stdio.h> #include <locale.h> #include <wchar.h> int main() { setlocale(L ...
- 最近被旷视的YOLOX刷屏了!
目录 论文主要信息 文章概要 背景 YOLOX-DarkNet53 实现细节 YOLOv3 baseline Decoupled head 实验 思路 story Strong data augmen ...
- 类似express的路由封装方式
1.原理 主要过程涉及三个元素的定义,如下: //用于承载一系列方法的对象 var funObj = {}; //用于根据条件执行funObj中的方法 var app = function(){}; ...
- 使用adb如何批量给设备安装apk
win系统 1.首先我们需要在本地建一个文件夹apks,然后把所要安装的apk放进去 2.打开dos窗口使用for循环进行安装即可(前提你的电脑已经连接上了设备,输入adb devices可查看) f ...
- 渗透测试思路 - CTF(番外篇)
渗透测试思路 Another:影子 (主要记录一下平时渗透的一些小流程和一些小经验) CTF(番外篇) 笔者是一个WEB狗,更多的是做一些WEB类型题目,只能怪笔者太菜,哭~~ 前言 本篇 ...
- vue点击复制功能
复制功能,选中复制或者点击复制(不使用插件的情况下) 1.选中复制 这个比点击复制简单点 <template> <div> <el-button type=& ...