]> arthur.barton.de Git - atom-ax-pipe.git/commitdiff
updated selectors and editor to work with latest Atom API
authorAndrew Willis <awillis@customink.com>
Fri, 6 Mar 2015 01:25:36 +0000 (20:25 -0500)
committerAndrew Willis <awillis@customink.com>
Fri, 6 Mar 2015 01:25:36 +0000 (20:25 -0500)
keymaps/pipe.cson
lib/command-view.coffee
lib/pipe.coffee
package.json

index d729528339931f12d986860a6b57469fa273cdf4..cd5b078c664f4c72df14e49f574f66e121f6cd79 100644 (file)
@@ -7,5 +7,5 @@
 
 # For more detailed documentation see
 # https://atom.io/docs/latest/advanced/keymaps
-'.editor':
+'.atom-text-editor':
   'cmd-;': 'pipe:run'
index 8ac7c49e34a59c90696baab07540892494e05ced..0b9e865b82e7b775d5948f5ef3bfed0b54dff338 100644 (file)
@@ -1,4 +1,5 @@
-{View, EditorView} = require 'atom'
+{View, TextEditorView} = require 'atom-space-pen-views'
+
 
 module.exports =
 class CommandView extends View
@@ -12,7 +13,7 @@ class CommandView extends View
 
   @content: ->
     @div class: 'pipe-command', =>
-      @subview 'commandLine', new EditorView(
+      @subview 'commandLine', new TextEditorView(
         mini: true
         placeholderText: @samplePlaceholder()
       )
index 3781a56ee719479af896dd1939568251a6478967..97ada8a8b67092cfa294a493be4fdc635a32694f 100644 (file)
@@ -6,7 +6,7 @@ history = []
 
 module.exports =
   activate: ->
-    atom.workspaceView.command 'pipe:run', => @run()
+    atom.commands.add 'atom-workspace', "pipe:run", => @run()
 
   run: ->
     editor = atom.workspace.getActiveEditor()
index 013f8a0139696e4aa2156e05bca00d3fba74108e..63934417d6454a8cd0298c256e32460652af56f2 100644 (file)
@@ -3,18 +3,20 @@
   "main": "./lib/pipe",
   "version": "0.3.2",
   "description": "Pipe text in and out of external commands.",
-  "activationEvents": [
-    "pipe:run"
-  ],
+  "activationCommands": {
+    "atom-workspace": "pipe:run"
+  },
   "repository": {
     "type": "git",
     "url": "https://github.com/moshee/atom-pipe"
   },
   "license": "MIT",
   "engines": {
-    "atom": ">0.72.0"
+    "atom": ">0.182.0 <2.0.0"
+  },
+  "dependencies": {
+    "atom-space-pen-views": ">2.0.0"
   },
-  "dependencies": {},
   "readme": "# pipe\n\nSelect text to pipe into external commands and replace it with the output. Sort\nof like `!` in vim. Commands are sent to your `$SHELL`.\n\nDefault keybinding to activate is `cmd-;`.\n\n![pipe in action](https://i.ktkr.us/hoeJ)\n",
   "readmeFilename": "README.md",
   "bugs": {