Skip to content
This repository has been archived by the owner on Nov 1, 2020. It is now read-only.

Commit

Permalink
Initial Package Skeleton
Browse files Browse the repository at this point in the history
  • Loading branch information
joefitzgerald committed Mar 22, 2016
0 parents commit de857ad
Show file tree
Hide file tree
Showing 10 changed files with 189 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"extends": "standard",
"parser": "babel-eslint",
"env": {
"browser": true,
"node": true,
"es6": true,
},
"globals": {
"atom": true,
},
"plugins": [
"promise"
],
}
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.DS_Store
npm-debug.log
node_modules
35 changes: 35 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
notifications:
email:
on_success: never
on_failure: change

script: 'curl -s https://raw.githubusercontent.com/atom/ci/master/build-package.sh | sh'

git:
depth: 10

sudo: false

os:
- linux
- osx

env:
global:
- APM_TEST_PACKAGES=""

matrix:
- ATOM_CHANNEL=stable
- ATOM_CHANNEL=beta

addons:
apt:
packages:
- build-essential
- git
- libgnome-keyring-dev
- fakeroot

branches:
only:
- master
20 changes: 20 additions & 0 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Copyright (c) 2016 Joe Fitzgerald

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# `run` [![Build Status](https://travis-ci.org/atom-community/run.svg?branch=master)](https://travis-ci.org/atom-community/run) [![Build status](https://ci.appveyor.com/api/projects/status/xjyljfplpwgcrtoe/branch/master?svg=true)](https://ci.appveyor.com/project/joefitzgerald/run/branch/master)

`run` launches your app using run providers.
27 changes: 27 additions & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
version: "{build}"

platform: x64

branches:
only:
- master

clone_depth: 10

skip_tags: true

environment:
APM_TEST_PACKAGES:

matrix:
- ATOM_CHANNEL: stable
- ATOM_CHANNEL: beta

install:
- ps: Install-Product node 5

build_script:
- ps: iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/atom/ci/master/build-package.ps1'))

test: off
deploy: off
18 changes: 18 additions & 0 deletions lib/main.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
'use babel'

import {CompositeDisposable} from 'atom'

export default {
subscriptions: null,

activate () {
this.subscriptions = new CompositeDisposable()
},

deactivate () {
if (this.subscriptions) {
this.subscriptions.dispose()
}
this.subscriptions = null
}
}
37 changes: 37 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
"name": "run",
"description": "Run your app using run providers.",
"keywords": [
"run",
"launch",
"invoke",
"spawn",
"exec"
],
"main": "./lib/main",
"version": "0.0.0",
"repository": "https://github.com/atom-community/run",
"license": "MIT",
"engines": {
"atom": ">=1.5.3 <2.0.0"
},
"author": "Joe Fitzgerald <[email protected]> (http://github.com/joefitzgerald)",
"homepage": "https://atom.io/packages/run",
"bugs": {
"url": "https://github.com/atom-community/run/issues"
},
"devDependencies": {
"eslint": "^2.4.0",
"babel-eslint": "^6.0.0-beta.6",
"eslint-config-standard": "^5.1.0",
"eslint-plugin-standard": "^1.3.2",
"eslint-plugin-promise": "^1.1.0"
},
"configSchema": {},
"standard": {
"globals": [
"atom",
"waitsForPromise"
]
}
}
8 changes: 8 additions & 0 deletions spec/.eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"env": {
"jasmine": true,
},
"globals": {
"waitsForPromise": true,
}
}
23 changes: 23 additions & 0 deletions spec/main-spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
'use babel'
/* eslint-env jasmine */

describe('run', () => {
let mainModule = null

beforeEach(() => {
waitsForPromise(() => {
return atom.packages.activatePackage('run').then((pack) => {
mainModule = pack.mainModule
})
})
})

describe('when the run package is activated', () => {
it('activates successfully', () => {
expect(mainModule).toBeDefined()
expect(mainModule).toBeTruthy()
expect(mainModule.subscriptions).toBeDefined()
expect(mainModule.subscriptions).toBeTruthy()
})
})
})

0 comments on commit de857ad

Please sign in to comment.