Permalink
Browse files

SO MUCH THINGS ๐Ÿป

- using bower
- bumped font-awesome, bootstrap and jquery
- grunt to build assets
- Procfile.dev to startup everything in watch mode
  • Loading branch information...
1 parent 6a69189 commit ae90d2a3625fa20f37cca7fc9b01805fdf95df0a @caarlos0 committed Oct 14, 2013
Showing with 935 additions and 9,608 deletions.
  1. +2 โˆ’0 .gitignore
  2. +4 โˆ’3 Gemfile
  3. +25 โˆ’10 Gemfile.lock
  4. +87 โˆ’0 Gruntfile.js
  5. +0 โˆ’19 Makefile
  6. +2 โˆ’0 Procfile.dev
  7. +12 โˆ’12 readme.markdown โ†’ README.md
  8. +2 โˆ’2 Rakefile
  9. +0 โˆ’31 _assets/bootstrap/accordion.less
  10. +0 โˆ’69 _assets/bootstrap/alerts.less
  11. +0 โˆ’51 _assets/bootstrap/badges.less
  12. +0 โˆ’63 _assets/bootstrap/bootstrap.less
  13. +0 โˆ’25 _assets/bootstrap/breadcrumbs.less
  14. +0 โˆ’170 _assets/bootstrap/button-groups.less
  15. +0 โˆ’159 _assets/bootstrap/buttons.less
  16. +0 โˆ’184 _assets/bootstrap/carousel.less
  17. +0 โˆ’33 _assets/bootstrap/close.less
  18. +0 โˆ’56 _assets/bootstrap/code.less
  19. +0 โˆ’23 _assets/bootstrap/component-animations.less
  20. +0 โˆ’168 _assets/bootstrap/dropdowns.less
  21. +0 โˆ’444 _assets/bootstrap/forms.less
  22. +0 โˆ’200 _assets/bootstrap/glyphicons.less
  23. +0 โˆ’204 _assets/bootstrap/grid.less
  24. +0 โˆ’29 _assets/bootstrap/jumbotron.less
  25. +0 โˆ’46 _assets/bootstrap/labels.less
  26. +0 โˆ’89 _assets/bootstrap/list-group.less
  27. +0 โˆ’56 _assets/bootstrap/media.less
  28. +0 โˆ’545 _assets/bootstrap/mixins.less
  29. +0 โˆ’137 _assets/bootstrap/modals.less
  30. +0 โˆ’377 _assets/bootstrap/navbar.less
  31. +0 โˆ’256 _assets/bootstrap/navs.less
  32. +0 โˆ’396 _assets/bootstrap/normalize.less
  33. +0 โˆ’55 _assets/bootstrap/pager.less
  34. +0 โˆ’108 _assets/bootstrap/pagination.less
  35. +0 โˆ’96 _assets/bootstrap/panels.less
  36. +0 โˆ’135 _assets/bootstrap/popovers.less
  37. +0 โˆ’89 _assets/bootstrap/print.less
  38. +0 โˆ’106 _assets/bootstrap/progress-bars.less
  39. +0 โˆ’119 _assets/bootstrap/responsive-utilities.less
  40. +0 โˆ’95 _assets/bootstrap/scaffolding.less
  41. +0 โˆ’262 _assets/bootstrap/tables.less
  42. +0 โˆ’42 _assets/bootstrap/thumbnails.less
  43. +0 โˆ’95 _assets/bootstrap/tooltip.less
  44. +0 โˆ’235 _assets/bootstrap/type.less
  45. +0 โˆ’42 _assets/bootstrap/utilities.less
  46. +0 โˆ’424 _assets/bootstrap/variables.less
  47. +0 โˆ’29 _assets/bootstrap/wells.less
  48. +0 โˆ’156 _assets/bootstrapjs/collapse.js
  49. +0 โˆ’47 _assets/bootstrapjs/transition.js
  50. +0 โˆ’84 _assets/fontawesome/bootstrap.less
  51. +0 โˆ’129 _assets/fontawesome/core.less
  52. +0 โˆ’93 _assets/fontawesome/extras.less
  53. +0 โˆ’1,953 _assets/fontawesome/font-awesome-ie7.less
  54. +0 โˆ’33 _assets/fontawesome/font-awesome.less
  55. +0 โˆ’381 _assets/fontawesome/icons.less
  56. +0 โˆ’48 _assets/fontawesome/mixins.less
  57. +0 โˆ’14 _assets/fontawesome/path.less
  58. +0 โˆ’735 _assets/fontawesome/variables.less
  59. +45 โˆ’42 _assets/up.less
  60. +22 โˆ’0 _includes/footer.html
  61. +42 โˆ’0 _includes/navbar.html
  62. +2 โˆ’65 _layouts/layout.html
  63. +2 โˆ’2 _layouts/post.html
  64. 0 about.html โ†’ about/index.html
  65. BIN apple-touch-icon-114x114-precomposed.png
  66. BIN apple-touch-icon-144x144-precomposed.png
  67. BIN apple-touch-icon-57x57-precomposed.png
  68. BIN apple-touch-icon-72x72-precomposed.png
  69. +22 โˆ’0 bower.json
  70. BIN css/font/FontAwesome.otf
  71. BIN css/font/fontawesome-webfont.eot
  72. +399 โˆ’0 css/font/fontawesome-webfont.svg
  73. BIN css/font/fontawesome-webfont.ttf
  74. BIN css/font/fontawesome-webfont.woff
  75. +3 โˆ’3 css/up.css
  76. BIN favicon.ico
  77. +244 โˆ’1 js/up.js
  78. +3 โˆ’0 js/up.min.js
  79. +11 โˆ’5 package.json
  80. +6 โˆ’0 script/init.sh
  81. +0 โˆ’28 script/update.sh
View
@@ -13,3 +13,5 @@ Thumbs.db
_assets/bootstrap/tests
node_modules/
+bower_components/
+components/
View
@@ -1,8 +1,9 @@
source 'https://rubygems.org'
-gem 'rake'
-gem 'rdiscount'
-gem 'jekyll'
+ruby '2.0.0'
+gem 'github-pages'
+gem 'rake'
gem 'rmagick'
+gem 'foreman'
View
@@ -1,44 +1,59 @@
GEM
remote: https://rubygems.org/
specs:
+ RedCloth (4.2.9)
classifier (1.3.3)
fast-stemmer (>= 1.0.0)
colorator (0.1)
- commander (4.1.3)
+ commander (4.1.5)
highline (~> 1.6.11)
directory_watcher (1.4.1)
+ dotenv (0.9.0)
fast-stemmer (1.0.2)
+ foreman (0.63.0)
+ dotenv (>= 0.7)
+ thor (>= 0.13.6)
+ github-pages (8)
+ RedCloth (= 4.2.9)
+ jekyll (= 1.2.0)
+ kramdown (= 1.0.2)
+ liquid (= 2.5.1)
+ maruku (= 0.6.1)
+ rdiscount (= 1.6.8)
+ redcarpet (= 2.2.2)
highline (1.6.19)
- jekyll (1.0.3)
+ jekyll (1.2.0)
classifier (~> 1.3)
colorator (~> 0.1)
commander (~> 4.1.3)
directory_watcher (~> 1.4.1)
- kramdown (~> 1.0.2)
- liquid (~> 2.3)
+ liquid (~> 2.5.1)
maruku (~> 0.5)
pygments.rb (~> 0.5.0)
+ redcarpet (~> 2.2.2)
safe_yaml (~> 0.7.0)
kramdown (1.0.2)
- liquid (2.5.0)
+ liquid (2.5.1)
maruku (0.6.1)
syntax (>= 1.0.0)
posix-spawn (0.3.6)
- pygments.rb (0.5.0)
+ pygments.rb (0.5.2)
posix-spawn (~> 0.3.6)
yajl-ruby (~> 1.1.0)
- rake (10.0.4)
- rdiscount (2.1.6)
+ rake (10.1.0)
+ rdiscount (1.6.8)
+ redcarpet (2.2.2)
rmagick (2.13.2)
safe_yaml (0.7.1)
syntax (1.0.0)
+ thor (0.18.1)
yajl-ruby (1.1.0)
PLATFORMS
ruby
DEPENDENCIES
- jekyll
+ foreman
+ github-pages
rake
- rdiscount
rmagick
View
@@ -0,0 +1,87 @@
+module.exports = function(grunt) {
+ grunt.initConfig({
+ pkg: grunt.file.readJSON('package.json'),
+ concat: {
+ dist: {
+ src: [
+ 'bower_components/jquery/jquery.min.js',
+ 'bower_components/bootstrap/js/transition.js',
+ 'bower_components/bootstrap/js/collapse.js',
+ '_assets/up.js'
+ ],
+ dest: 'js/up.js'
+ }
+ },
+ uglify: {
+ build: {
+ src: 'js/up.js',
+ dest: 'js/up.min.js'
+ }
+ },
+ less: {
+ development: {
+ options: {
+ paths: [
+ '_assets/',
+ 'bower_components/bootstrap/less/',
+ 'bower_components/font-awesome/less/'
+ ]
+ },
+ files: {
+ 'css/up.css': '_assets/up.less'
+ }
+ },
+ production: {
+ options: {
+ paths: [
+ '_assets/',
+ 'bower_components/bootstrap/less/',
+ 'bower_components/font-awesome/less/'
+ ],
+ yuicompress: true
+ },
+ files: {
+ 'css/up.css': '_assets/up.less'
+ }
+ }
+ },
+ watch: {
+ scripts: {
+ files: ['_assets/*.js'],
+ tasks: ['concat', 'uglify'],
+ options: {
+ spawn: false,
+ },
+ },
+ less: {
+ // We watch and compile sass files as normal but don't live reload here
+ files: ['_assets/*.less'],
+ tasks: ['less'],
+ },
+ },
+ copy: {
+ main: {
+ files: [
+ {
+ expand: true,
+ flatten: true,
+ cwd: 'bower_components/font-awesome/font/',
+ src: '**',
+ dest: 'css/font/',
+ filter: 'isFile'
+ }
+ ]
+ }
+ }
+ });
+
+ // Load the plugins
+ grunt.loadNpmTasks('grunt-contrib-concat');
+ grunt.loadNpmTasks('grunt-contrib-uglify');
+ grunt.loadNpmTasks('grunt-contrib-less');
+ grunt.loadNpmTasks('grunt-contrib-watch');
+ grunt.loadNpmTasks('grunt-contrib-copy');
+
+ // Default task(s).
+ grunt.registerTask('default', ['concat', 'uglify', 'less', 'copy']);
+};
View
@@ -1,19 +0,0 @@
-CHECK=โœ”
-HR=\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#\#
-
-build:
- @echo "${HR}"
- @echo "Building UP assets..."
- @echo "${HR}"
- @recess --compress _assets/up.less > css/up.css
- @echo "Compiling and Compressing Less and CSS files with Recess... ${CHECK} Done"
- @cat _assets/bootstrapjs/* > js/up.js.tmp
- @cat _assets/up.js >> js/up.js.tmp
- @uglifyjs js/up.js.tmp > js/up.js
- @rm -rf js/up.js.tmp
- @echo "Compiling and Compressing JS files with uglify-js... ${CHECK} Done"
- @echo "${HR}"
- @echo "UP successfully built."
- @echo "${HR}"
- @echo "<3 @caarlos0"
-
View
@@ -0,0 +1,2 @@
+web: rake preview
+assets: grunt watch
@@ -22,8 +22,9 @@ a base for whole thing.
- [Fork this repository](https://github.com/caarlos0/up/fork)
- Rename it to `YOUR-USER.github.io`
- Clone it: `git clone https://github.com/YOUR-USER/YOUR-USER.github.io`
-- Run the bundler in the blog folder to get the dependencies: `bundle`
-- Run the jekyll server: `rake preview`.
+- With Ruby, bundler, Node.js and NPM previously installed, run the init script
+`./scripts/init`;
+- Start it up in watch mode: `foreman start -f Procfile.dev`.
You should have a server up and running locally at <http://localhost:4000>.
@@ -34,27 +35,26 @@ change is the following:
- [_config.yml](https://github.com/caarlos0/up/blob/gh-pages/_config.yml): Put
your config there, almost everything will be up and running.
-- [about.html](https://github.com/caarlos0/up/blob/gh-pages/about.html): Well, that's
-about you, I would change it if I were you... OH WAIT!
+- [about/index.html](https://github.com/caarlos0/up/blob/gh-pages/about/index.html):
+Well, that's about you, I would change it if I were you... OH WAIT!
- [CNAME](https://github.com/caarlos0/up/blob/gh-pages/CNAME): If you're using
this on GitHub Pages with a custom domain name, you might want to change this to be
the domain you're going to use. All that should be in here is a
domain name on the first line and nothing else (like: `example.com`).
- [favicon.ico](https://github.com/caarlos0/up/blob/gh-pages/favicon.ico): This
is a smaller version of my gravatar for use as the icon in your browser's
-address bar. You may change it to whatever you like.
+address bar. You may change it to whatever you like. [Updating your icons][up-icons].
- [apple-touch-icon.jpg](https://github.com/caarlos0/up/blob/gh-pages/apple-touch-icon.jpg):
Again, this is my gravatar, and it shows up in iOS and various other apps
-that use this file as an "icon" for your site.
+that use this file as an "icon" for your site. [Updating your icons][up-icons].
-### Custom CSS/JS
+[up-icons]: https://github.com/caarlos0/up#update-favicon-and-apple-precomposed-icons-based-on-gravatar
-If you need custom CSS or JS, you will need `node.js'` `npm` executable in
-your `PATH`, as well `recess` and `uglify-js`. To do this, after installed
-`npm`, in your blog folder, run: `npm install`.
+### Custom CSS/JS
-It will install `recess` and `uglify-js` executables for you. Now, do your
-changes in `less` and/or `js` files, and run `make` to compile the files.
+Assets are now managed by bower. You could simply run `grunt` whenever you
+want to update your assets. `grunt watch` will also watch everything for
+changes.
Note: I'm not using any Jekyll asset pipeline because it's not supported
by [GitHub Pages](http://pages.github.com), so, I prefer to do it by myself.
View
@@ -49,7 +49,7 @@ end # task :post
desc "Launch preview environment"
task :preview do
- system "jekyll serve --watch"
+ system "bundle exec jekyll serve --watch --drafts"
end # task :preview
desc "Update icons based on your gravatar (define author email in _config.yml)!"
@@ -79,7 +79,7 @@ task :icons do
end
puts "Creating favicon.ico..."
- Magick::Image::read(origin).first.resize(16, 16).write("favicon.ico")
+ Magick::Image::read(origin).first.resize(32, 32).write("favicon.ico")
[144, 114, 72, 57].each do |size|
puts "Creating #{name_pre} icon..." % [size, size]
@@ -1,31 +0,0 @@
-//
-// Accordion
-// --------------------------------------------------
-
-
-// Parent container
-.accordion {
- margin-bottom: @line-height-computed;
-}
-
-// Group == heading + body
-.accordion-group {
- margin-bottom: 2px;
- border: 1px solid #e5e5e5;
- border-radius: @border-radius-base;
-}
-.accordion-heading {
- border-bottom: 0;
-
- .accordion-toggle {
- display: block;
- padding: 8px 15px;
- cursor: pointer;
- }
-}
-
-// Inner needs the styles because you can't animate properly with any styles on the element
-.accordion-inner {
- padding: 9px 15px;
- border-top: 1px solid #e5e5e5;
-}
@@ -1,69 +0,0 @@
-//
-// Alerts
-// --------------------------------------------------
-
-
-// Base styles
-// -------------------------
-
-.alert {
- padding: 10px 35px 10px 15px;
- margin-bottom: @line-height-computed;
- color: @alert-text;
- background-color: @alert-bg;
- border: 1px solid @alert-border;
- border-radius: @alert-border-radius;
-
- // Headings for larger alerts
- h4 {
- margin-top: 0;
- // Specified for the h4 to prevent conflicts of changing @headingsColor
- color: inherit;
- }
- // Match the hr to the border of the alert
- hr {
- border-top-color: darken(@alert-border, 5%);
- }
- // Provide class for links that match alerts
- .alert-link {
- font-weight: 500;
- color: darken(@alert-text, 10%);
- }
-
- // Adjust close link position
- .close {
- position: relative;
- top: -2px;
- right: -21px;
- color: inherit;
- }
-}
-
-// Alternate styles
-// -------------------------
-
-.alert-success {
- .alert-variant(@alert-success-bg, @alert-success-border, @alert-success-text);
-}
-.alert-danger {
- .alert-variant(@alert-danger-bg, @alert-danger-border, @alert-danger-text);
-}
-.alert-info {
- .alert-variant(@alert-info-bg, @alert-info-border, @alert-info-text);
-}
-
-// Block alerts
-// -------------------------
-
-.alert-block {
- padding-top: 15px;
- padding-bottom: 15px;
-
- > p,
- > ul {
- margin-bottom: 0;
- }
- p + p {
- margin-top: 5px;
- }
-}
Oops, something went wrong.

0 comments on commit ae90d2a

Please sign in to comment.