Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes by ChibiShibe #54

Open
wants to merge 139 commits into
base: master
Choose a base branch
from
Open

Conversation

chibishibe
Copy link

Re-instated the following behaviors:
-Greet
-Eventbrite
-countdown

Changes to Greet:
indexed it
Added personality

Changes to eventbrite:
Re-instated Token
Re-instated no peek function
Added heightened personality to no peek

Changes to Clap:
Changed Class name to fit behaviour

Changes to countdown:
Fixed Time format, stopped console error

~~New additions
"Do the impossible" behavior key-phrase response
-Reference to TTGL anime show
"Shake"
-Converts messages sent via "!shake" to Gif emoji varients"

~~Other changes
Swapped icons around, Began centralizing

chibishibe and others added 30 commits February 21, 2018 13:15
Let's try this shall we? 
Duped Section that normally scream when you roll more than 100
It kept spitting out "(Please enter number of dice being rolled and Number of Sides like "!rtd 1d5)" for every roll because input.
1d100 function reply doesn't work
No input still returning null
Gave a little personality
because promises amiright?
Changed keys and tokens. LET'S FIRE
Response back
Added Greet
whoops Round 2
back to planet, remove the space
no space here either
lets try a comma
Back to square 1?
not a total revision
Zero
goddamnitall
damndamnda
Turns out we might need it?
killme
Copy link
Owner

@imjoshdean imjoshdean left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A lot of non-difficult changes. Looking good, just needs polish!

package.json Outdated
@@ -48,6 +48,8 @@
"rimraf": "^2.5.2"
},
"dependencies": {
"airtable": "^0.5.2",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't being used, please remove.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh shoot, this PR's off a branch, isn't it...
That's in place pending implementation as a Karma backend (soon).
If you want, we can revert and drop a branch with this deleted at ~that point in time :)

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can also just throw up another commit removing the dependencies, less work for you.

package.json Outdated
@@ -48,6 +48,8 @@
"rimraf": "^2.5.2"
},
"dependencies": {
"airtable": "^0.5.2",
"eslint-plugin-jsx-a11y": "^6.0.3",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't being used, please remove.

@@ -1,28 +1,28 @@
import Behavior from '../behavior.js';

class RollTheDice extends Behavior {
class ClaporRave extends Behavior {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Capitalize your "o" with CamelCase you capitalize every letter. So ClapOrRave

constructor(settings) {
settings.name = 'Clap Hype';
settings.description = `'cause 👏 sometimes 👏 you 👏 need 👏 emphasis!`;
settings.name = 'ClappingRave';
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Split these words, the name is more meant to be user readable.

});
['clap', 'rubyrave', 'wut'].forEach(emoji => this.commands.push({
tag: emoji,
description: `I'll hype your message, !Clap or !Rave`
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will !Clap work, or only !clap? You should make sure what users see is what they can use. I've tried to strive for all lower case for these where possible.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed, Pesky Shift Trigger Finger.

Will lowercase

@@ -0,0 +1,2 @@
var letters = ["a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z"].map(alpha => ":sh-" + alpha + ":");
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file can be deleted, as it is not used.


parseMessage(message, channel, data) {
let splitMessage = message.replace(/^!shake/gi, '')
.replace(/\:\w*\:/gi, '')
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's bring down the indentation a bit, only needs to be two spaces from the let. 👌

.replace(/[^a-zA-Z ]/g, '')
.trim()
.split('');
if( splitMessage.length > 20) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trim the spacing before splitMessage

}

const parsedMessage = splitMessage.map(alpha => alpha == " " ? ":ws:" : `:sh-${alpha}:`);

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary whitespace. In general this file has some wonky spacing on it. Try and clean it up, tab === two spaces please.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other things I'm noticing, please use single quotes, not double quotes throughout.

@@ -23,8 +31,8 @@ const mascot = new MascotBot({
{
behavior: DaysUntil,
settings: {
conDate: '8/11/2017',
maxDays: 398,
conDate: '2018-07-26 09-05:00',
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't a valid date. Maybe stick to a simpler format.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Our local test disagrees '-'
That's not quite ISO 8601, but I believe the library which supports parsing those to times was complaining that the previous version was going to be deprecated, so we saw to it to change it to this form. (It's missing MM:SS and T, isn't it :)
ISO 8601 is pretty unambiguous, would you prefer it in proper form instead?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I didn't realize that was ISO-8601, as long as moment has no problems with it!

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, when I went to run the countdown behaviour for the first time. I encountered a Depreciation Warning in console. It worked, it just threw a warning out, so I tweaked the format a bit in order to keep a clean console

clap -> Changed to emp, added functionality
days until -> Changed errors in indent
eventbrite - > Added correct amount of periods for ellipsis personality
greet -> changed to lowercase for icon
introductions -> reverted all changed to intoductions and messages
messages -> see above
Removed rave structure -> combined into changed emp
Removed array -> No longer needed
shake.js -> Fixed indenting and removed whitespace
indec -> Removed rave entry, added emp
Index.js -> Forgot to remove clap.js changed to emp.js
Copy link
Owner

@imjoshdean imjoshdean left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still a lot of changes suggested not yet implemented, and a few more from here.

@@ -1,22 +1,22 @@
import Behavior from '../behavior.js';

class ClaporRave extends Behavior {
class Emp extends Behavior {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use meaningful names and try to refrain from confusing abbreviations or shortened versions of words. While you might understand what they mean, other developers may not. Emphasis would be easier to understand.

const parsedMessage = splitMessage.map(alpha => alpha == " " ? ":ws:" : `:sh-${alpha}:`);

let splitMessage = message.replace(/^!shake/gi, '')
.replace(/\:\w*\:/gi, '')
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one is my bad for not being the clearest, you should definitely indent, but generally it's one tab off the current indentation so rather than

let splitMessage = message.replace(/^!shake/gi, '')
.replace(/\:\w*\:/gi, '')
let splitMessage = message.replace(/^!shake/gi, '')
  .replace(/\:\w*\:/gi, '')
``

chibishibe and others added 4 commits February 27, 2018 13:56
Removed non-current dependencies from package. ((airtable + eslint))
Changed name of "emp" to "emphasis" to improve clarity
Fixed indenting on 1:1 scale with shake
replaced changes in index ((Emp -> emphasis))
GitCola will be my GitGui on Raspberri Pi, I need to test a commit

-Tweak response to greet.js
Post help in only one message

Tested, working correctly. Merging
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants