Skip to content

Commit

Permalink
add files
Browse files Browse the repository at this point in the history
  • Loading branch information
forabi committed Feb 20, 2014
1 parent c440aa4 commit 89d0cd8
Show file tree
Hide file tree
Showing 43 changed files with 13,450 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .bowerrc
@@ -0,0 +1,3 @@
{
"directory": "app/bower_components"
}
21 changes: 21 additions & 0 deletions .editorconfig
@@ -0,0 +1,21 @@
# EditorConfig helps developers define and maintain consistent
# coding styles between different editors and IDEs
# editorconfig.org

root = true


[*]

# Change these settings to your own preference
indent_style = space
indent_size = 4

# We recommend you to keep these unchanged
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
trim_trailing_whitespace = false
1 change: 1 addition & 0 deletions .gitattributes
@@ -0,0 +1 @@
* text=auto
6 changes: 6 additions & 0 deletions .gitignore
@@ -0,0 +1,6 @@
node_modules
temp
.tmp
dist
.sass-cache
app/bower_components
24 changes: 24 additions & 0 deletions .jshintrc
@@ -0,0 +1,24 @@
{
"node": true,
"browser": true,
"esnext": true,
"bitwise": true,
"camelcase": true,
"curly": true,
"eqeqeq": true,
"immed": true,
"indent": 4,
"latedef": true,
"newcap": true,
"noarg": true,
"quotmark": "single",
"regexp": true,
"undef": true,
"unused": true,
"strict": true,
"trailing": true,
"smarttabs": true,
"globals" : {
"chrome": true
}
}
289 changes: 289 additions & 0 deletions Gruntfile.js
@@ -0,0 +1,289 @@
/*jshint camelcase: false*/
// Generated on 2014-02-20 using generator-chromeapp 0.2.5
'use strict';

// # Globbing
// for performance reasons we're only matching one level down:
// 'test/spec/{,*/}*.js'
// use this if you want to recursively match all subfolders:
// 'test/spec/**/*.js'

module.exports = function (grunt) {
// show elapsed time at the end
require('time-grunt')(grunt);
// load all grunt tasks
require('load-grunt-tasks')(grunt);

grunt.initConfig({
yeoman: {
app: 'app',
dist: 'dist'
},
watch: {
options: {
spawn: false
},
livereload: {
options: {
livereload: '<%= connect.livereload.options.livereload %>'
},
files: [
'<%= yeoman.app %>/*.html',
'<%= yeoman.app %>/styles/{,*/}*.css',
'<%= yeoman.app %>/scripts/{,*/}*.js',
'<%= yeoman.app %>/images/{,*/}*.{png,jpg,jpeg,gif,webp,svg}',
'<%= yeoman.app %>/manifest.json',
'<%= yeoman.app %>/_locales/{,*/}*.json'
]
}
},
connect: {
options: {
port: 9000,
// change this to '0.0.0.0' to access the server from outside
hostname: 'localhost'
},
livereload: {
options: {
livereload: 35729,
base: [
'<%= yeoman.app %>'
]
}
},
test: {
options: {
base: [
'test',
'<%= yeoman.app %>'
]
}
}
},
clean: {
dist: {
files: [{
dot: true,
src: [
'<%= yeoman.dist %>/*',
'!<%= yeoman.dist %>/.git*'
]
}]
}
},
jshint: {
options: {
jshintrc: '.jshintrc',
reporter: require('jshint-stylish')
},
all: [
'Gruntfile.js',
'<%= yeoman.app %>/scripts/{,*/}*.js',
'test/spec/{,*/}*.js'
]
},
mocha: {
all: {
options: {
run: true,
urls: ['http://localhost:<%= connect.options.port %>/index.html']
}
}
},
// Compiles Sass to CSS and generates necessary files if requested
compass: {
options: {
sassDir: '<%= yeoman.app %>/styles',
cssDir: '.tmp/styles',
generatedImagesDir: '.tmp/images/generated',
imagesDir: '<%= yeoman.app %>/images',
javascriptsDir: '<%= yeoman.app %>/scripts',
fontsDir: '<%= yeoman.app %>/styles/fonts',
importPath: '<%= yeoman.app %>/bower_components',
httpImagesPath: '/images',
httpGeneratedImagesPath: '/images/generated',
httpFontsPath: '/styles/fonts',
relativeAssets: false,
assetCacheBuster: false
},
dist: {
options: {
generatedImagesDir: '<%= yeoman.dist %>/images/generated'
}
}
},
useminPrepare: {
options: {
dest: '<%= yeoman.dist %>'
},
html: [
'<%= yeoman.app %>/index.html'
]
},
usemin: {
options: {
dirs: ['<%= yeoman.dist %>']
},
html: ['<%= yeoman.dist %>/{,*/}*.html'],
css: ['<%= yeoman.dist %>/styles/{,*/}*.css']
},
imagemin: {
dist: {
files: [{
expand: true,
cwd: '<%= yeoman.app %>/images',
src: '{,*/}*.{gif,jpeg,jpg,png}',
dest: '<%= yeoman.dist %>/images'
}]
}
},
svgmin: {
dist: {
files: [{
expand: true,
cwd: '<%= yeoman.app %>/images',
src: '{,*/}*.svg',
dest: '<%= yeoman.dist %>/images'
}]
}
},
htmlmin: {
dist: {
options: {
// removeCommentsFromCDATA: true,
// collapseWhitespace: true,
// collapseBooleanAttributes: true,
// removeAttributeQuotes: true,
// removeRedundantAttributes: true,
// useShortDoctype: true,
// removeEmptyAttributes: true,
// removeOptionalTags: true
},
files: [{
expand: true,
cwd: '<%= yeoman.app %>',
src: '*.html',
dest: '<%= yeoman.dist %>'
}]
}
},

// By default, your `index.html`'s <!-- Usemin block --> will take care of
// minification. These next options are pre-configured if you do not wish
// to use the Usemin blocks.
// cssmin: {
// dist: {
// files: {
// '<%= yeoman.dist %>/styles/main.css': [
// '.tmp/styles/{,*/}*.css',
// '<%= yeoman.app %>/styles/{,*/}*.css'
// ]
// }
// }
// },
// uglify: {
// dist: {
// files: {
// '<%= yeoman.dist %>/scripts/scripts.js': [
// '<%= yeoman.dist %>/scripts/scripts.js'
// ]
// }
// }
// },
// concat: {
// dist: {}
// },

// Put files not handled in other tasks here
copy: {
dist: {
files: [{
expand: true,
dot: true,
cwd: '<%= yeoman.app %>',
dest: '<%= yeoman.dist %>',
src: [
'*.{ico,png,txt}',
'images/{,*/}*.{webp,gif}',
'_locales/{,*/}*.json',
'styles/fonts/{,*/}*.*'
]
}]
}
},
concurrent: {
dist: [
'compass:dist',
'imagemin',
'svgmin',
'htmlmin'
]
},
chromeManifest: {
dist: {
options: {
buildnumber: true,
background: {
target: 'scripts/background.js',
exclude: [
'scripts/chromereload.js'
]
}
},
src: '<%= yeoman.app %>',
dest: '<%= yeoman.dist %>'
}
},
compress: {
dist: {
options: {
archive: 'package/quran for chrome.zip'
},
files: [{
expand: true,
cwd: 'dist/',
src: ['**'],
dest: ''
}]
}
}
});

grunt.registerTask('debug', function (opt) {
if (opt && opt === 'jshint') {
var watch = grunt.config('watch');
watch.livereload.tasks.push('jshint');
grunt.config('watch', watch);
}

grunt.task.run([
'jshint',
'connect:livereload',
'watch'
]);
});

grunt.registerTask('test', [
'connect:test',
'mocha'
]);

grunt.registerTask('build', [
'clean:dist',
'chromeManifest:dist',
'useminPrepare',
'concurrent:dist',
'cssmin',
'concat',
'uglify',
'copy',
'usemin',
'compress'
]);

grunt.registerTask('default', [
'jshint',
'test',
'build'
]);
};
2 changes: 1 addition & 1 deletion README.md
@@ -1,4 +1,4 @@
rome
quran-for-chrome
================

A Chrome packaged app for reading The Holy Quran
Expand Down
5 changes: 5 additions & 0 deletions README.md~
@@ -0,0 +1,5 @@
rome
================

A Chrome packaged app for reading The Holy Quran

10 changes: 10 additions & 0 deletions app/_locales/en/messages.json
@@ -0,0 +1,10 @@
{
"appName": {
"message": "Quran for Chrome",
"description": "The name of the application"
},
"appDescription": {
"message": "An advanced, offline-enabled Quranic research tool with many translations and recitations available.",
"description": "The description of the application"
}
}
Binary file added app/images/icon-128.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/images/icon-16.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions app/index.html
@@ -0,0 +1,17 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Quran for Chrome</title>
<!-- build:css styles/main.css -->
<link rel="stylesheet" href="styles/main.css">
<!-- endbuild -->
</head>
<body>
<h1>'Allo</h1>

<!-- build:js scripts/index.js -->
<script src="scripts/index.js"></script>
<!-- endbuild -->
</body>
</html>

0 comments on commit 89d0cd8

Please sign in to comment.