Skip to content

Commit

Permalink
Merge pull request #1581 from hubot-new/2023-catchup
Browse files Browse the repository at this point in the history
feat: activity on repo has been stalled, this kickstarts it #1541
  • Loading branch information
technicalpickles committed Apr 17, 2023
2 parents 3ebc399 + d709cce commit a1af4c8
Show file tree
Hide file tree
Showing 26 changed files with 10,049 additions and 163 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/nodejs-macos.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Node.js (macOS) CI

on:
push:
branches: [ "master" ]
schedule:
- cron: '5 4 * * 0'

jobs:
npm-test:

runs-on: macos-latest

strategy:
matrix:
node-version: [18.x]

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm test
28 changes: 28 additions & 0 deletions .github/workflows/nodejs-ubuntu.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Node.js (Ubuntu) CI

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
schedule:
- cron: '5 4 * * 0'

jobs:
npm-test:

runs-on: ubuntu-latest

strategy:
matrix:
node-version: [14.x, 16.x, 18.x, latest]

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm test
26 changes: 26 additions & 0 deletions .github/workflows/nodejs-windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Node.js (Windows) CI

on:
push:
branches: [ "master" ]
schedule:
- cron: '5 4 * * 0'

jobs:
npm-test:

runs-on: windows-latest

strategy:
matrix:
node-version: [18.x]

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm test
37 changes: 0 additions & 37 deletions ROADMAP.md

This file was deleted.

6 changes: 1 addition & 5 deletions bin/hubot.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const options = {
adapter: process.env.HUBOT_ADAPTER || 'shell',
alias: process.env.HUBOT_ALIAS || false,
create: process.env.HUBOT_CREATE || false,
enableHttpd: process.env.HUBOT_HTTPD || true,
enableHttpd: process.env.HUBOT_HTTPD !== 'false',
scripts: process.env.HUBOT_SCRIPTS || [],
name: process.env.HUBOT_NAME || 'Hubot',
path: process.env.HUBOT_PATH || '.',
Expand Down Expand Up @@ -80,10 +80,6 @@ Parser.on((opt, value) => {

Parser.parse(process.argv)

if (process.platform !== 'win32') {
process.on('SIGTERM', () => process.exit(0))
}

if (options.create) {
console.error("'hubot --create' is deprecated. Use the yeoman generator instead:")
console.error(' npm install -g yo generator-hubot')
Expand Down
10 changes: 5 additions & 5 deletions docs/deploying/windows.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ Hasn't been fully tested - YMMV

There are 4 primary steps to deploying and running hubot on a Windows machine:

* node and npm
* a way to get source code updated on the server
* setting up environment variables for hubot
* a way to start hubot, start it up if it crashes, and restart it when code updates
* node and npm
* a way to get source code updated on the server
* setting up environment variables for hubot
* a way to start hubot, start it up if it crashes, and restart it when code updates

## node and npm

To start, your windows server will need node and npm.
The best way to do this is with [chocolatey](http://chocolatey.org) using the [nodejs.install](http://chocolatey.org/packages/nodejs.install) package.
I've found that sometimes the system path variable is not correctly set; ensure you can run node/npm from the command line. If needed set the PATH variable with "setx PATH \"%PATH%;C:\Program Files\nodejs\" "
I've found that sometimes the system path variable is not correctly set; ensure you can run node/npm from the command line. If needed set the PATH variable with `set PATH=%PATH%;\"C:\Program Files\nodejs\"`

Your other option is to install directly from [NodeJS](https://nodejs.org/) and run the current download (v0.12.4 as of this documentation). This should set your PATH variables for you.

Expand Down
14 changes: 14 additions & 0 deletions docs/patterns.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,3 +218,17 @@ Organizations that have a number of chat rooms that serve different purposes oft

Work on generalized blacklist solution is [ongoing](https://github.com/kristenmills/hubot-command-blacklist). A whitelist soultion could take a similar approach.

## Use scoped npm packages as adapter

It is possible to [install](https://docs.npmjs.com/cli/v7/commands/npm-install) package under a custom alias:

```bash
npm install <alias>@npm:<name>
```

So for example to use `@foo/hubot-adapter` package as the adapter, you can:
```bash
npm install hubot-foo@npm:@foo/hubot-adapter

bin/hubot --adapter foo
```
2 changes: 1 addition & 1 deletion es2015.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module.exports = {
User,
Brain,
Robot,
Adapter: Adapter,
Adapter,
Response,
Listener: Listener.Listener,
TextListener: Listener.TextListener,
Expand Down
Loading

0 comments on commit a1af4c8

Please sign in to comment.