Commits

Meikel Brandmeyer  committed b345b15

Revert nrepl changes

  • Participants
  • Parent commits a58ed0d

Comments (0)

Files changed (2)

File build.gradle

     apply plugin: 'java-base'
 
     group = 'vimclojure'
-    version = '2.3.0-nrepl-SNAPSHOT'
+    version = '2.3.0-SNAPSHOT'
 
     defaultTasks 'build'
 }
 
     repositories {
         clojureReleasesRepo()
-        clojarsRepo()
     }
 
     dependencies {
-        development 'org.clojure:clojure:1.2.+'
-        development 'org.clojars.kotarak:nrepl:0.0.2-SNAPSHOT'
+        development 'org.clojure:clojure:1.2.0'
     }
 
     uploadArchives {
     ]
 }
 
-task runRepl(type: JavaExec.class, dependsOn: project(':server').classes) {
+task runNailgun(type: JavaExec.class, dependsOn: project(':server').classes) {
     classpath = project.files(
         project(':server').sourceSets.main.clojure.sourceDir,
         project(':server').sourceSets.main.classesDir,
         project(':server').sourceSets.main.compileClasspath
     )
-    main = 'clojure.tools.nrepl.main'
-    args = [ "--port", "2187" ]
+    main = 'vimclojure.nailgun.NGServer'
+    args = [ '127.0.0.1' ]
 }

File vim/autoload/vimclojure.vim

 	return vimclojure#WithSavedOption(closure)
 endfunction
 
-function! vimclojure#Stringify(text)
-	return '"' . escape(a:text, '\"') . '"'
-endfunction
-
-function! vimclojure#CreateFrame(options)
-	return "" . len(a:options) . "\n" .
-				\ join(
-				\   values(
-				\     map(copy(a:options),
-				\       'vimclojure#Stringify(v:key) . "\n"' .
-				\       '. vimclojure#Stringify(v:val)')),
-				\   "\n")
-endfunction
-
-function! vimclojure#ItemEnd(line)
-	let i = len(a:line) - 1
-
-	if a:line[i] != '"'
-		return 0
-	endif
-
-	let even = 1
-	while i > 0
-		let i -= 1
-		if a:line[i] != '\'
-			return even
-		endif
-
-		let even = (even + 1) % 2
-	endwhile
-
-	return even
-endfunction
-
-function! vimclojure#ReadItem(input)
-	let [l; input] = a:input
-
-	if l[0] != '"' || vimclojure#ItemEnd(l)
-		execute "let result = " . l
-		return [result, input]
-	endif
-
-	let item = [l]
-	while input != []
-		let [l; input] = input
-
-		call add(item, l)
-		if vimclojure#ItemEnd(l)
-			execute "let result = " . join(item, "\n")
-			return [result, input]
-		endif
-	endwhile
-
-	echoerr "Unexpected EOF while reading item"
-endfunction
-
-function! vimclojure#ReadFrame(input)
-	let frame = {}
-
-	let [ssize; input] = a:input
-	execute "let size = " . ssize
-	if size == 0
-		return [frame, input]
-	endif
-
-	for i in range(size)
-		let [k, input] = vimclojure#ReadItem(input)
-		let [v, input] = vimclojure#ReadItem(input)
-		let frame[k] = v
-	endfor
-
-	return [frame, input]
-endfunction
-
-function! vimclojure#ReadFrames(input)
-	let frames = []
-	let input = a:input
-
-	while input != []
-		let [frame, input] = vimclojure#ReadFrame(input)
-		call add(frames, frame)
-	endwhile
-
-	return frames
-endfunction
-
-function! vimclojure#StringifyArguments(args)
-	return join(map(copy(a:args), 'vimclojure#Stringify(v:val)'), " ")
-endfunction
-
 function! vimclojure#ExecuteNailWithInput(nail, input, ...)
 	if type(a:input) == type("")
 		let input = split(a:input, '\n', 1)