Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion packages/gitmoji-changelog-website
Submodule gitmoji-changelog-website deleted from 56dcff
20 changes: 20 additions & 0 deletions packages/gitmoji-changelog-website/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# EditorConfig helps developers define and maintain consistent
# coding styles between different editors and IDEs
# editorconfig.org

root = true


[*]
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
indent_style = space
indent_size = 2

[*.hbs]
insert_final_newline = false

[*.{diff,md}]
trim_trailing_whitespace = false
9 changes: 9 additions & 0 deletions packages/gitmoji-changelog-website/.ember-cli
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
/**
Ember CLI sends analytics information by default. The data is completely
anonymous, but there are times when you might want to disable this behavior.

Setting `disableAnalytics` to true will prevent any data from being sent.
*/
"disableAnalytics": false
}
20 changes: 20 additions & 0 deletions packages/gitmoji-changelog-website/.eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# unconventional js
/blueprints/*/files/
/vendor/

# compiled output
/dist/
/tmp/

# dependencies
/bower_components/
/node_modules/

# misc
/coverage/
!.*

# ember-try
/.node_modules.ember-try/
/bower.json.ember-try
/package.json.ember-try
54 changes: 54 additions & 0 deletions packages/gitmoji-changelog-website/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
module.exports = {
root: true,
parser: 'babel-eslint',
parserOptions: {
ecmaVersion: 2018,
sourceType: 'module',
ecmaFeatures: {
legacyDecorators: true
}
},
plugins: [
'ember'
],
extends: [
'eslint:recommended',
'plugin:ember/recommended'
],
env: {
browser: true
},
rules: {
'ember/no-jquery': 'error'
},
overrides: [
// node files
{
files: [
'.eslintrc.js',
'.template-lintrc.js',
'ember-cli-build.js',
'testem.js',
'blueprints/*/index.js',
'config/**/*.js',
'lib/*/index.js',
'server/**/*.js'
],
parserOptions: {
sourceType: 'script'
},
env: {
browser: false,
node: true
},
plugins: ['node'],
rules: Object.assign({}, require('eslint-plugin-node').configs.recommended.rules, {
// add your custom rules and overrides for node files here

// this can be removed once the following is fixed
// https://github.com/mysticatea/eslint-plugin-node/issues/77
'node/no-unpublished-require': 'off'
})
}
]
};
25 changes: 25 additions & 0 deletions packages/gitmoji-changelog-website/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# See https://help.github.com/ignore-files/ for more about ignoring files.

# compiled output
/dist/
/tmp/

# dependencies
/bower_components/
/node_modules/

# misc
/.env*
/.pnp*
/.sass-cache
/connect.lock
/coverage/
/libpeerconnection.log
/npm-debug.log*
/testem.log
/yarn-error.log

# ember-try
/.node_modules.ember-try/
/bower.json.ember-try
/package.json.ember-try
5 changes: 5 additions & 0 deletions packages/gitmoji-changelog-website/.template-lintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
'use strict';

module.exports = {
extends: 'octane'
};
34 changes: 34 additions & 0 deletions packages/gitmoji-changelog-website/.travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
language: node_js
node_js:
- "8"

sudo: false
dist: trusty

addons:
chrome: stable

cache:
yarn: true

env:
global:
# See https://git.io/vdao3 for details.
- JOBS=1

branches:
only:
- master

before_install:
- curl -o- -L https://yarnpkg.com/install.sh | bash
- export PATH=$HOME/.yarn/bin:$PATH

install:
- yarn install --non-interactive

script:
- yarn lint:hbs
- yarn lint:js
- yarn test
3 changes: 3 additions & 0 deletions packages/gitmoji-changelog-website/.watchmanconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"ignore_dirs": ["tmp", "dist"]
}
58 changes: 58 additions & 0 deletions packages/gitmoji-changelog-website/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# gitmoji-changelog-website

This README outlines the details of collaborating on this Ember application.
A short introduction of this app could easily go here.

## Prerequisites

You will need the following things properly installed on your computer.

* [Git](https://git-scm.com/)
* [Node.js](https://nodejs.org/)
* [Yarn](https://yarnpkg.com/)
* [Ember CLI](https://ember-cli.com/)
* [Google Chrome](https://google.com/chrome/)

## Installation

* `git clone <repository-url>` this repository
* `cd gitmoji-changelog-website`
* `yarn install`

## Running / Development

* `ember serve`
* Visit your app at [http://localhost:4200](http://localhost:4200).
* Visit your tests at [http://localhost:4200/tests](http://localhost:4200/tests).

### Code Generators

Make use of the many generators for code, try `ember help generate` for more details

### Running Tests

* `ember test`
* `ember test --server`

### Linting

* `yarn lint:hbs`
* `yarn lint:js`
* `yarn lint:js --fix`

### Building

* `ember build` (development)
* `ember build --environment production` (production)

### Deploying

Specify what it takes to deploy your app.

## Further Reading / Useful Links

* [ember.js](https://emberjs.com/)
* [ember-cli](https://ember-cli.com/)
* Development Browser Extensions
* [ember inspector for chrome](https://chrome.google.com/webstore/detail/ember-inspector/bmdblncegkenkacieihfhpjfppoconhi)
* [ember inspector for firefox](https://addons.mozilla.org/en-US/firefox/addon/ember-inspector/)
12 changes: 12 additions & 0 deletions packages/gitmoji-changelog-website/app/app.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import Application from '@ember/application';
import Resolver from 'ember-resolver';
import loadInitializers from 'ember-load-initializers';
import config from './config/environment';

export default class App extends Application {
modulePrefix = config.modulePrefix;
podModulePrefix = config.podModulePrefix;
Resolver = Resolver;
}

loadInitializers(App, config.modulePrefix);
Empty file.
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<section aria-label="repository input">
<h2>Type your repository's url</h2>
<form {{on "submit" this.onSubmit}}>
<label for="repository" class="visuallyhidden">Repository's url</label>
<input
id="repository"
name="repository"
type="text"
value={{this.repositoryUrl}}
{{on "keydown" this.updateRepositoryUrl}}
placeholder="https://github.com/frinyvonnick/gitmoji-changelog.git"
/>
{{#if this.changelog}}
<section aria-label="changelog">
{{markdown-to-html this.changelog}}
</section>
{{/if}}
{{#if this.loading}}
<section aria-label="changelog">
<p>Loading...</p>
</section>
{{/if}}
</form>
</section>
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
import Component from "@glimmer/component";
import { tracked } from "@glimmer/tracking";
import { action } from "@ember/object";

export default class RepositoryInputComponent extends Component {
@tracked repositoryUrl
@tracked changelog = ''
@tracked loading = false

@action
onSubmit(e) {
e.preventDefault()
this.loading = true
fetch(`http://localhost:9999/?repository=${this.repositoryUrl}`)
.then(res => res.text())
.then(changelog => {
const formattedChangelog = changelog
.split('\n')
.slice(1)
.join('\n')
this.changelog = formattedChangelog
this.loading = false
})
.catch((err) => {
console.error(err)
})
Comment on lines +24 to +26

Choose a reason for hiding this comment

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

no this.loading = false in catch part ?

}

@action
updateRepositoryUrl(e) {
this.repositoryUrl = e.target.value
}
}
4 changes: 4 additions & 0 deletions packages/gitmoji-changelog-website/app/components/usage.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<section aria-label="usage">
<h2>Open your terminal and execute the following command:</h2>
<pre>npx gitmoji-changelog</pre>
</section>
Empty file.
Empty file.
27 changes: 27 additions & 0 deletions packages/gitmoji-changelog-website/app/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>GitmojiChangelogWebsite</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">

{{content-for "head"}}

<link integrity="" rel="stylesheet" href="{{rootURL}}assets/vendor.css">
<link integrity="" rel="stylesheet" href="{{rootURL}}assets/gitmoji-changelog-website.css">

<link href="https://fonts.googleapis.com/css?family=Roboto:300,400,700&display=swap" rel="stylesheet">

{{content-for "head-footer"}}
</head>
<body>
{{content-for "body"}}

<script src="{{rootURL}}assets/vendor.js"></script>
<script src="{{rootURL}}assets/gitmoji-changelog-website.js"></script>

{{content-for "body-footer"}}
</body>
</html>
Empty file.
10 changes: 10 additions & 0 deletions packages/gitmoji-changelog-website/app/router.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import EmberRouter from '@ember/routing/router';
import config from './config/environment';

export default class Router extends EmberRouter {
location = config.locationType;
rootURL = config.rootURL;
}

Router.map(function() {
});
Empty file.
Loading