embersketch 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: befefa4390fb63132bbfe1419bbc2cf26a119288
4
+ data.tar.gz: 21c9ede7e8fd5bc2220035da6a5b145f5e75808e
5
+ SHA512:
6
+ metadata.gz: 42fc91e8ee80ae7e982fb8fbb425b3a041596e3253ae7f70ab7f9b17c4dcd1232252f629c69566e727be0f3793da394934ad19bcf8db56e7b54a08b785a1fae6
7
+ data.tar.gz: 4433cfb0ae893d9d38c6b682649f2fe93ad7038098dbc0dd51685c3af6397de03ec2bf1697d98e9c7953c233cfa41f5a15a5ca07ff0ad52332930c1e99c64199
data/.gitignore ADDED
@@ -0,0 +1,23 @@
1
+ .DS_Store
2
+ *.gem
3
+ *.rbc
4
+ .bundle
5
+ .config
6
+ .yardoc
7
+ Gemfile.lock
8
+ InstalledFiles
9
+ _yardoc
10
+ coverage
11
+ doc/
12
+ lib/bundler/man
13
+ pkg
14
+ rdoc
15
+ spec/reports
16
+ test/tmp
17
+ test/version_tmp
18
+ tmp
19
+ *.bundle
20
+ *.so
21
+ *.o
22
+ *.a
23
+ mkmf.log
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in embersketch.gemspec
4
+ gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2014 John McDowall
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,29 @@
1
+ # Embersketch
2
+
3
+ Ember Sketch is a minimalist project thumbnail generator. It's as simple to use as JSBin, but with all the benefits of local storage and versioning.
4
+
5
+ You'd use this to quickly test out an idea, develop a component and so on. Basically anything that doesn't warrant creating a full blown ```ember-cli``` project or the like.
6
+
7
+ Ember Sketch will create a [Middleman](http://middlemanapp.com) based website for you, that includes a very simple default structure (including SASS support with Compass) and a super simple starter Ember app.
8
+
9
+ This probably could be a generator of some sorts built into ```ember-cli```, and maybe that's where it will end up in the future.
10
+
11
+ ## Installation
12
+
13
+ Install it yourself as:
14
+
15
+ $ gem install embersketch
16
+
17
+ ## Usage
18
+
19
+ Ember Sketch only understands one command: ```new```. To generate a new Ember sketch, say:
20
+
21
+ $ embersketch new <project_name>
22
+
23
+ ## Contributing
24
+
25
+ 1. Fork it ( https://github.com/[my-github-username]/embersketch/fork )
26
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
27
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
28
+ 4. Push to the branch (`git push origin my-new-feature`)
29
+ 5. Create a new Pull Request
data/Rakefile ADDED
@@ -0,0 +1,2 @@
1
+ require "bundler/gem_tasks"
2
+
data/bin/embersketch ADDED
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'rubygems'
4
+ require 'embersketch'
5
+
6
+ EmberSketch::EmberSketch.start
@@ -0,0 +1,24 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'embersketch/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "embersketch"
8
+ spec.version = Embersketch::VERSION
9
+ spec.authors = ["John McDowall"]
10
+ spec.email = ["john@mcdowall.info"]
11
+ spec.summary = %q{A tool for generating quick self hosting Ember thumbnail sketches using Middleman.}
12
+ spec.description = %q{}
13
+ spec.homepage = ""
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0")
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_dependency "thor"
22
+ spec.add_development_dependency "bundler", "~> 1.6"
23
+ spec.add_development_dependency "rake"
24
+ end
@@ -0,0 +1,3 @@
1
+ module Embersketch
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,27 @@
1
+ require "embersketch/version"
2
+ require 'thor'
3
+
4
+ module EmberSketch
5
+ class EmberSketch < Thor
6
+ include Thor::Actions
7
+
8
+ desc "new PROJECT_NAME", "Creates a new Ember Sketch project in a directory called PROJECT_NAME"
9
+ def new(project_name)
10
+ create_directory_structure(project_name)
11
+ end
12
+
13
+ def source_paths
14
+ [File.join(File.expand_path(File.dirname(__FILE__)), ".")]
15
+ end
16
+
17
+ private
18
+
19
+ def create_directory_structure(project_name)
20
+ empty_directory project_name
21
+ directory("./templates", "#{project_name}/.")
22
+ say "Running bundler...", :green
23
+ run("cd #{project_name} && bundle")
24
+ say "Launch your ember sketch with: bundle exec middleman", :green
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,14 @@
1
+ # If you have OpenSSL installed, we recommend updating
2
+ # the following line to use "https"
3
+ source 'http://rubygems.org'
4
+
5
+ gem "middleman", "~>3.3.5"
6
+
7
+ # Live-reloading plugin
8
+ gem "middleman-livereload", "~> 3.3.4"
9
+
10
+ # For faster file watcher updates on Windows:
11
+ gem "wdm", "~> 0.1.0", :platforms => [:mswin, :mingw]
12
+
13
+ # Windows does not come with time zone data
14
+ gem "tzinfo-data", platforms: [:mswin, :mingw]
@@ -0,0 +1 @@
1
+ web: bundle exec middleman -p $PORT
@@ -0,0 +1 @@
1
+ # Ember Sketch
@@ -0,0 +1,36 @@
1
+ # Reload the browser automatically whenever files change
2
+ activate :livereload
3
+
4
+ ###
5
+ # Compass
6
+ ###
7
+ compass_config do |config|
8
+ config.output_style = :compressed
9
+ end
10
+
11
+ ###
12
+ # Helpers
13
+ ###
14
+ helpers do
15
+ def get_url
16
+ absolute_prefix + url_prefix
17
+ end
18
+ end
19
+
20
+ ###
21
+ # Config
22
+ ###
23
+ set :css_dir, 'stylesheets'
24
+ set :js_dir, 'javascripts'
25
+ set :images_dir, 'images'
26
+ set :url_prefix, '/'
27
+ set :absolute_prefix, 'http://localhost:4567'
28
+
29
+ # Build-specific configuration
30
+ configure :build do
31
+ puts "local build"
32
+ set :url_prefix, ""
33
+ set :absolute_prefix, ""
34
+ activate :asset_hash
35
+ activate :minify_css
36
+ end
File without changes
@@ -0,0 +1,4 @@
1
+ ---
2
+ title: Ember Sketch
3
+ description:
4
+ ---
@@ -0,0 +1,13 @@
1
+ <!doctype html>
2
+ <html>
3
+ <head>
4
+ <%= partial "partials/head" %>
5
+ <%= partial "partials/templates" %>
6
+ </head>
7
+ <body class="<%= page_classes %>">
8
+ <div class="content">
9
+ <div class='application_container'></div>
10
+ </div>
11
+ <%= partial "partials/javascripts" %>
12
+ </body>
13
+ </html>
@@ -0,0 +1,7 @@
1
+ <meta charset="utf-8">
2
+ <meta name="viewport" content="initial-scale=1">
3
+ <!-- Always force latest IE rendering engine or request Chrome Frame -->
4
+ <meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
5
+ <title><%= current_page.data.title %></title>
6
+ <%= stylesheet_link_tag "main", {media: false} %>
7
+ <meta name="description" content="<%= current_page.data.description %>" />
@@ -0,0 +1,39 @@
1
+ <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
2
+ <script src="http://builds.handlebarsjs.com.s3.amazonaws.com/handlebars-v1.3.0.js"></script>
3
+ <script src="http://builds.emberjs.com/release/ember.js"></script>
4
+ <script src="http://builds.emberjs.com/canary/ember-data.js"></script>
5
+
6
+ <script type='text/javascript'>
7
+
8
+ App = Ember.Application.create({
9
+ rootElement: '.application_container'
10
+ });
11
+
12
+ App.ApplicationAdapter = DS.FixtureAdapter.extend();
13
+
14
+ App.Item = DS.Model.extend({
15
+ title: DS.attr('string')
16
+ });
17
+
18
+ App.Item.FIXTURES = [
19
+ {
20
+ id: 1,
21
+ "title": "cat",
22
+ },
23
+ {
24
+ id: 2,
25
+ "title": "dog"
26
+ }
27
+ ];
28
+
29
+ App.Router.map(function() {
30
+ // put your routes here
31
+ });
32
+
33
+ App.IndexRoute = Ember.Route.extend({
34
+ model: function() {
35
+ return this.store.find('item');
36
+ }
37
+ });
38
+
39
+ </script>
@@ -0,0 +1,15 @@
1
+ <script type="text/x-handlebars">
2
+ <h2>Welcome to Ember Sketch</h2>
3
+
4
+ {{outlet}}
5
+ </script>
6
+
7
+ <script type="text/x-handlebars" data-template-name="index">
8
+ <ul>
9
+ {{#each item in model}}
10
+ <li>
11
+ {{item.title}}
12
+ </li>
13
+ {{/each}}
14
+ </ul>
15
+ </script>
@@ -0,0 +1,25 @@
1
+ // global declarations
2
+ * {
3
+ -moz-box-sizing: border-box;
4
+ box-sizing: border-box;
5
+ }
6
+
7
+
8
+ body {
9
+ background-color: #fff;
10
+ color: $default-text-color;
11
+ display: table;
12
+ font-family: 'Helvetica';
13
+ font-size: percentage($default-font-size/16px);
14
+ height: 100%;
15
+ line-height: $default-line-height;
16
+ padding-bottom: 4em;
17
+ padding-top: 4em;
18
+ margin: 0;
19
+ width: 100%;
20
+ }
21
+
22
+ .content {
23
+ max-width: 1100px;
24
+ margin: 0 auto;
25
+ }
@@ -0,0 +1,23 @@
1
+ // colors
2
+ $default-text-color : #4C4E4D;
3
+
4
+ // breakpoints
5
+ $break_xsmall : 400px;
6
+ $break_small : 600px;
7
+ $break_medium_small : 728px;
8
+ $break_medium : 880px;
9
+ $break_large_medium : 950px;
10
+ $break_large : 1080px;
11
+ $break_xlarge_large : 1200px;
12
+ $break_xlarge : 1500px;
13
+ $break_xxlarge : 1600px;
14
+
15
+ // layout
16
+ $default-width : 1080px;
17
+ $gutter-vertical : 15px;
18
+ $gutter-horizontal : 25px;
19
+ $sidebar-width : 325px;
20
+ $sidebar-width-narrow : 160px;
21
+
22
+ $default-font-size : 16px;
23
+ $default-line-height : (25px/$default-font-size);
@@ -0,0 +1,7 @@
1
+ @charset "utf-8";
2
+ @import 'compass';
3
+
4
+ @import 'vars';
5
+ @import 'fonts';
6
+ @import 'globals';
7
+
File without changes
metadata ADDED
@@ -0,0 +1,112 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: embersketch
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - John McDowall
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-08-25 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: thor
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: bundler
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.6'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.6'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rake
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ description: ''
56
+ email:
57
+ - john@mcdowall.info
58
+ executables:
59
+ - embersketch
60
+ extensions: []
61
+ extra_rdoc_files: []
62
+ files:
63
+ - ".gitignore"
64
+ - Gemfile
65
+ - LICENSE.txt
66
+ - README.md
67
+ - Rakefile
68
+ - bin/embersketch
69
+ - embersketch.gemspec
70
+ - lib/embersketch.rb
71
+ - lib/embersketch/version.rb
72
+ - lib/templates/Gemfile
73
+ - lib/templates/Procfile
74
+ - lib/templates/README.md
75
+ - lib/templates/config.rb
76
+ - lib/templates/source/images/.gitkeep
77
+ - lib/templates/source/index.html.erb
78
+ - lib/templates/source/layouts/layout.erb
79
+ - lib/templates/source/partials/_head.html.erb
80
+ - lib/templates/source/partials/_javascripts.html.erb
81
+ - lib/templates/source/partials/_templates.html.erb
82
+ - lib/templates/source/stylesheets/_fonts.scss
83
+ - lib/templates/source/stylesheets/_globals.scss
84
+ - lib/templates/source/stylesheets/_vars.scss
85
+ - lib/templates/source/stylesheets/main.scss
86
+ - lib/templates/source/stylesheets/modules/.gitkeep
87
+ homepage: ''
88
+ licenses:
89
+ - MIT
90
+ metadata: {}
91
+ post_install_message:
92
+ rdoc_options: []
93
+ require_paths:
94
+ - lib
95
+ required_ruby_version: !ruby/object:Gem::Requirement
96
+ requirements:
97
+ - - ">="
98
+ - !ruby/object:Gem::Version
99
+ version: '0'
100
+ required_rubygems_version: !ruby/object:Gem::Requirement
101
+ requirements:
102
+ - - ">="
103
+ - !ruby/object:Gem::Version
104
+ version: '0'
105
+ requirements: []
106
+ rubyforge_project:
107
+ rubygems_version: 2.4.1
108
+ signing_key:
109
+ specification_version: 4
110
+ summary: A tool for generating quick self hosting Ember thumbnail sketches using Middleman.
111
+ test_files: []
112
+ has_rdoc: