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

Commit

Permalink
Merge branch 'master' into CrossR/CodeBlockHighlights
Browse files Browse the repository at this point in the history
# Conflicts:
#	main/src/main.ts
  • Loading branch information
CrossR committed Jul 25, 2018
2 parents dd60df3 + c465082 commit a3baa76
Show file tree
Hide file tree
Showing 204 changed files with 10,741 additions and 2,327 deletions.
14 changes: 7 additions & 7 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<!-- Want this issue prioritized? Please consider supporting the project and becoming an insider!
👉 https://www.onivim.io/Insiders -->

Oni Version:
Neovim Version (Linux only):
Operating System:
**Oni Version:**
**Neovim Version (Linux only):**
**Operating System:**

#### Describe your issue
**Issue:**

#### Expected behaviour
**Expected behavior:**

#### Actual behaviour
**Actual behavior:**

#### Steps to reproduce
**Steps to reproduce:**
1 change: 1 addition & 0 deletions .github/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,4 @@ backers:
- 244396
- 8832878
- 5127194
- 1764368
26 changes: 25 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,30 @@
sudo: required
dist: trusty
language: node_js

branches:
only:
- master
- /^release.*/

cache:
directories:
- .oni_build_cache

matrix:
include:
- os: linux
sudo: required
dist: trusty
node_js: 8
- os: osx
- os: osx # OSX 10.12
node_js: 8
- os: osx # OSX 10.11
node_js: 8
osx_image: xcode8
allow_failures:
- osx_image: xcode8

addons:
apt:
packages:
Expand All @@ -26,15 +35,30 @@ addons:
- xz-utils
- rpm
- bsdtar

before_install:
- |
# Get the files modified in this commit, and check there is
# actual code changes made. If there isn't, stop the build.
MODIFIED_FILES=$(git diff --name-only $TRAVIS_COMMIT_RANGE)
if ! echo ${MODIFIED_FILES} | grep -qvE '(\.md$)/'; then
echo "Only documents were updated, stopping..."
exit
fi
install:
- npm install -g yarn
- yarn install

script:
- npm run check-cached-binaries
- ./build/script/install-reason.sh
- ./build/script/travis-build.sh
- travis_wait ./build/script/travis-pack.sh
- ./build/script/travis-test.sh

deploy:
- provider: s3
access_key_id: AKIAIYMATI2CEFTHPBOQ
Expand Down
9 changes: 9 additions & 0 deletions BACKERS.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,15 @@ Thanks you to all our backers for making Oni possible!
* Alex
* Phil Plückthun
* Norikazu Hayashi
* Paul Anderson
* Thomas Frick
* LinuxLefty
* Leon Bogaert
* Jorrit Siebelink
* Zac Sims
* Doug Beney
* Aditya Gudimella
* Michal Hantl

<a href="https://opencollective.com/oni/tiers/backer/0/website" target="_blank"><img src="https://opencollective.com/oni/tiers/backer/0/avatar.png"></a>
<a href="https://opencollective.com/oni/tiers/backer/1/website" target="_blank"><img src="https://opencollective.com/oni/tiers/backer/1/avatar.png"></a>
Expand Down
44 changes: 22 additions & 22 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ First, thank you for considering contributing to oni! It's people like you that

We welcome any type of contribution, not only code. You can help with

* **QA**: file bug reports, the more details you can give the better (e.g. screenshots with the console open)
* **Marketing**: writing blog posts, howto's, printing stickers, ...
* **Community**: presenting the project at meetups, organizing a dedicated meetup for the local community, ...
* **Code**: take a look at the [open issues](issues). Even if you can't write code, commenting on them, showing that you care about a given issue matters. It helps us triage them.
* **Money**: we welcome financial contributions in full transparency on our [open collective](https://opencollective.com/oni).
* **QA**: file bug reports, the more details you can give the better (e.g. screenshots with the console open)
* **Marketing**: writing blog posts, howto's, printing stickers, ...
* **Community**: presenting the project at meetups, organizing a dedicated meetup for the local community, ...
* **Code**: take a look at the [open issues](issues). Even if you can't write code, commenting on them, showing that you care about a given issue matters. It helps us triage them.
* **Money**: we welcome financial contributions in full transparency on our [open collective](https://opencollective.com/oni).

## Your First Contribution

Expand All @@ -22,11 +22,11 @@ Any code change should be submitted as a pull request. The description should ex

## Code review guidelines

* Keep PRs **small and scoped**. The bigger the pull request, the longer it will take to review and merge. Break down large pull requests into smaller incremental chunks - this will help catch issues earlier and be easier on both you and the maintainer.
* Following from the previous bullet point, **do not include unrelated changes in a PR**. It can be tempting to include extra styling changes or additional functionality, but these should be added as separate PRs.
* Think of each PR as **improving the quality of the codebase**. Codebases tend towards entropy and disorder unless actively managed - make sure that your change moves the quality needle in the right direction. This can take a variety of forms, including adding test coverage, reducing coupling, etc. _As we are a small team moving fast, we cannot afford to accumulate technical debt._
* If there is ambiguity in terms of design, architecture, or implementation, it's best to get **feedback before implementing**, to save both you and the maintainer time. If you're not sure, feel free to ask!
* For your first few PRs, **don't try and change the world** - pick some small issues and get familiar with the codebase. Then, work your way up to bigger issues - this will set you up for success.
* Keep PRs **small and scoped**. The bigger the pull request, the longer it will take to review and merge. Break down large pull requests into smaller incremental chunks - this will help catch issues earlier and be easier on both you and the maintainer.
* Following from the previous bullet point, **do not include unrelated changes in a PR**. It can be tempting to include extra styling changes or additional functionality, but these should be added as separate PRs.
* Think of each PR as **improving the quality of the codebase**. Codebases tend towards entropy and disorder unless actively managed - make sure that your change moves the quality needle in the right direction. This can take a variety of forms, including adding test coverage, reducing coupling, etc. _As we are a small team moving fast, we cannot afford to accumulate technical debt._
* If there is ambiguity in terms of design, architecture, or implementation, it's best to get **feedback before implementing**, to save both you and the maintainer time. If you're not sure, feel free to ask!
* For your first few PRs, **don't try and change the world** - pick some small issues and get familiar with the codebase. Then, work your way up to bigger issues - this will set you up for success.

PRs require approval from one other person, either a maintainer or a contributor. Keep in mind that when you approve code, you are accountable for it, too! Reviewers are the gatekeepers of quality and ensuring adherence to the guidelines above.

Expand All @@ -39,33 +39,33 @@ Anyone can file an expense. If the expense makes sense for the development of th

The primary allotment of our [open collective](https://opencollective.com/oni) budget is dedicated to bounties. Developing features and fixing bugs is a lot of work, and those go directly to the developers doing this work via bounties. It is the role of the _maintainer_ to set bounties and clear completion criteria. Issues that have a bounty associated with them will have a `bounty` label as well as an amount, ie, `bounty-50` means a $50 bounty.

* Guidelines:
* The fix for the bug/feature/issue _MUST_ be complete and _MUST_ be covered by tests to be eligible for a bounty.
* Any associated documentation relevant to the bug/feature _MUST_ be updated.
* If you begin working on an issue with an associated bounty, open a PR with "WIP" and the bug number in the title, as well as reference the issue #. This is important to reduce duplicate work.
* Guidelines:
* The fix for the bug/feature/issue _MUST_ be complete and _MUST_ be covered by tests to be eligible for a bounty.
* Any associated documentation relevant to the bug/feature _MUST_ be updated.
* If you begin working on an issue with an associated bounty, open a PR with "WIP" and the bug number in the title, as well as reference the issue #. This is important to reduce duplicate work.

#### Claiming a bounty

* Upon completion of an issue with an associated bounty, bounties are payable by [Submitting an Expense](https://opencollective.com/oni/expenses/new) on our [OpenCollective](https://opencollective.com/oni). Note that OpenCollective requires a PDF or Photo of an expense form for an expense claim to be accepted - more information, including an example expense form can be found [here](https://opencollective.com/faq#expense). Check out our [expenses](https://opencollective.com/oni/expenses#) page for an example.
* A collaborator will approve the expense once we have verified it meets the criteria outlined above (complete fix, covered by tests, associated documentation updated)
* Upon completion of an issue with an associated bounty, bounties are payable by [Submitting an Expense](https://opencollective.com/oni/expenses/new) on our [OpenCollective](https://opencollective.com/oni). Note that OpenCollective requires a PDF or Photo of an expense form for an expense claim to be accepted - more information, including an example expense form can be found [here](https://opencollective.com/faq#expense). Check out our [expenses](https://opencollective.com/oni/expenses#) page for an example.
* A collaborator will approve the expense once we have verified it meets the criteria outlined above (complete fix, covered by tests, associated documentation updated)

If you questions about the guidelines, please don't hesitate to contact the maintainer.

## Roles

There are various roles and responsibilities in managing an open-source project. Users that are active and have a positive impact on the project and community will be recognized and have the option of assuming additional responsibilities.

* **Maintainer** - A maintainer communicates goals and drives the vision for the project. The maintainer is responsible for breaking down hurdles and supporting contributors. In addition, the maintainer triages issues, produces releases, assigns bounties, and establishes completion criteria. Today, there is one maintainer, but that isn't a strict requirement.
* **Collaborator** - A collaborator is an established member of the project that is recognized for their impact and contributions. They can triage and close issues, approve PRs from other contributors / collaborators, and can approve expenses on our [open collective](https://opencollective.com/oni)
* **Contributor** - A contributor is a developer that has submitted a successful PR for the project.
* **Maintainer** - A maintainer communicates goals and drives the vision for the project. The maintainer is responsible for breaking down hurdles and supporting contributors. In addition, the maintainer triages issues, produces releases, assigns bounties, and establishes completion criteria. Today, there is one maintainer, but that isn't a strict requirement.
* **Collaborator** - A collaborator is an established member of the project that is recognized for their impact and contributions. They can triage and close issues, approve PRs from other contributors / collaborators, and can approve expenses on our [open collective](https://opencollective.com/oni)
* **Contributor** - A contributor is a developer that has submitted a successful PR for the project.

### Becoming a collaborator

A collaborator is a contributor who has been recognized for the impact they've had on the project, over a sustained period of time. In general, this means the following:

* **Supporting the community** - helping others in issues and chat, supporting new developers, creating a positive and supportive environment.
* **Technical impact** - involvement in a core technical piece of the editor, or a broad impact on the ecosystem.
* **Positive and collaborative mindset** - creating good vibes, willingness to give and receive constructive feedback, being a team player.
* **Supporting the community** - helping others in issues and chat, supporting new developers, creating a positive and supportive environment.
* **Technical impact** - involvement in a core technical piece of the editor, or a broad impact on the ecosystem.
* **Positive and collaborative mindset** - creating good vibes, willingness to give and receive constructive feedback, being a team player.

## Questions

Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

### Modern Modal Editing

[![Build Status](https://travis-ci.org/onivim/oni.svg?branch=master)](https://travis-ci.org/onivim/oni) [![Build Status](https://ci.appveyor.com/api/projects/status/gum9hty9hm65o7ae/branch/master?svg=true)](https://ci.appveyor.com/project/onivim/oni/branch/master)[![codecov](https://codecov.io/gh/onivim/oni/branch/master/graph/badge.svg)](https://codecov.io/gh/onivim/oni)
[![Build Status](https://travis-ci.org/onivim/oni.svg?branch=master)](https://travis-ci.org/onivim/oni) [![Build status](https://ci.appveyor.com/api/projects/status/s13bs7ail9ihkpnm?svg=true)](https://ci.appveyor.com/project/oni/oni) [![codecov](https://codecov.io/gh/onivim/oni/branch/master/graph/badge.svg)](https://codecov.io/gh/onivim/oni)

[![Join the chat on discord!](https://img.shields.io/discord/417774914645262338.svg)](https://discord.gg/7maEAxV)
[![Backers on Open Collective](https://opencollective.com/oni/backers/badge.svg)](https://opencollective.com/oni#backer) [![BountySource Active Bounties](https://api.bountysource.com/badge/tracker?tracker_id=48462304)](https://www.bountysource.com/teams/oni)
[![Total Downloads](https://img.shields.io/github/downloads/onivim/oni/total.svg)](https://github.com/onivim/oni/releases)
Expand Down
8 changes: 7 additions & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ branches:
- master
- /^release.*/

# Skip CI build if the changes match these rules exactly.
# Ie, if the BACKERS.md file is changed, we don't need to build.
skip_commits:
files:
- '**/*.md'

cache:
- .oni_build_cache -> package.json

Expand All @@ -28,7 +34,7 @@ install:
- npm --version
# install modules
- yarn install
- npm run check-cached-binaries
- yarn run check-cached-binaries

artifacts:
- path: dist/*.exe
Expand Down
31 changes: 22 additions & 9 deletions browser/src/App.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Entry point for the Oni application - managing the overall lifecycle
*/

import { ipcRenderer } from "electron"
import { ipcRenderer, remote } from "electron"
import * as fs from "fs"
import * as minimist from "minimist"
import * as path from "path"
Expand Down Expand Up @@ -47,6 +47,11 @@ export const quit = async (): Promise<void> => {
Log.info("[App.quit] Quit hook completed successfully")
})
await Promise.all([promises])
// On mac we should quit the application when the user press Cmd + Q
if (process.platform === "darwin") {
Log.info("[App::quit] quitting app")
remote.app.quit()
}
Log.info("[App::quit] completed")
}

Expand Down Expand Up @@ -84,10 +89,10 @@ export const start = async (args: string[]): Promise<void> => {
const globalCommandsPromise = import("./Services/Commands/GlobalCommands")
const inputManagerPromise = import("./Services/InputManager")
const languageManagerPromise = import("./Services/Language")
const vcsManagerPromise = import("./Services/VersionControl")
const notificationsPromise = import("./Services/Notifications")
const snippetPromise = import("./Services/Snippets")
const keyDisplayerPromise = import("./Services/KeyDisplayer")
const quickOpenPromise = import("./Services/QuickOpen")
const taksPromise = import("./Services/Tasks")
const terminalPromise = import("./Services/Terminal")
const workspacePromise = import("./Services/Workspace")
Expand Down Expand Up @@ -225,14 +230,11 @@ export const start = async (args: string[]): Promise<void> => {
Menu.activate(configuration, overlayManager)
const menuManager = Menu.getInstance()

const QuickOpen = await quickOpenPromise
QuickOpen.activate(commandManager, menuManager, editorManager, workspace)

const Notifications = await notificationsPromise
Notifications.activate(configuration, overlayManager)
const notifications = Notifications.getInstance()

if (typeof developmentPluginError !== "undefined") {
const notifications = Notifications.getInstance()
const notification = notifications.createItem()
notification.setContents(developmentPluginError.title, developmentPluginError.errorText)
notification.setLevel("error")
Expand All @@ -243,7 +245,6 @@ export const start = async (args: string[]): Promise<void> => {
}

configuration.onConfigurationError.subscribe(err => {
const notifications = Notifications.getInstance()
const notification = notifications.createItem()
notification.setContents("Error Loading Configuration", err.toString())
notification.setLevel("error")
Expand Down Expand Up @@ -313,14 +314,25 @@ export const start = async (args: string[]): Promise<void> => {
Sidebar.activate(configuration, workspace)
const sidebarManager = Sidebar.getInstance()

const VCSManager = await vcsManagerPromise
VCSManager.activate(
workspace,
editorManager,
statusBar,
commandManager,
menuManager,
sidebarManager,
notifications,
configuration,
)

Explorer.activate(
commandManager,
configuration,
editorManager,
Sidebar.getInstance(),
workspace,
)
Search.activate(commandManager, editorManager, Sidebar.getInstance(), workspace)
Learning.activate(
commandManager,
configuration,
Expand All @@ -341,6 +353,7 @@ export const start = async (args: string[]): Promise<void> => {

Performance.startMeasure("Oni.Start.Activate")
const api = pluginManager.startApi()
Search.activate(api)
configuration.activate(api)

Snippets.activateProviders(
Expand Down Expand Up @@ -395,7 +408,7 @@ export const start = async (args: string[]): Promise<void> => {
Bookmarks.activate(configuration, editorManager, Sidebar.getInstance())

const PluginsSidebarPane = await import("./Plugins/PluginSidebarPane")
PluginsSidebarPane.activate(configuration, pluginManager, sidebarManager)
PluginsSidebarPane.activate(commandManager, configuration, pluginManager, sidebarManager)

const Terminal = await terminalPromise
Terminal.activate(commandManager, configuration, editorManager)
Expand Down
Loading

0 comments on commit a3baa76

Please sign in to comment.