Skip to content

Commit 22b9d3f

Browse files
committed
Added package ui files for controlling permissions
1 parent e533278 commit 22b9d3f

14 files changed

+4775
-0
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
dist/
2+
node_modules/
3+
tmp/
4+
Umbraco.Test/
5+
.sass-cache/
Lines changed: 158 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,158 @@
1+
2+
module.exports = function(grunt) {
3+
require('load-grunt-tasks')(grunt);
4+
var path = require('path');
5+
6+
grunt.initConfig({
7+
pkg: grunt.file.readJSON('package.json'),
8+
pkgMeta: grunt.file.readJSON('config/meta.json'),
9+
dest: grunt.option('target') || 'dist',
10+
basePath: path.join('<%= dest %>', 'App_Plugins', '<%= pkgMeta.name %>'),
11+
12+
watch: {
13+
options: {
14+
spawn: false,
15+
atBegin: true
16+
},
17+
js: {
18+
files: ['source/**/*.js'],
19+
tasks: ['concat:dist']
20+
},
21+
html: {
22+
files: ['source/**/*.html'],
23+
tasks: ['copy:html']
24+
},
25+
sass: {
26+
files: ['source/**/*.scss'],
27+
tasks: ['sass', 'copy:css']
28+
},
29+
css: {
30+
files: ['source/**/*.css'],
31+
tasks: ['copy:css']
32+
},
33+
manifest: {
34+
files: ['source/package.manifest'],
35+
tasks: ['copy:manifest']
36+
}
37+
},
38+
39+
concat: {
40+
options: {
41+
stripBanners: false
42+
},
43+
dist: {
44+
src: [
45+
'source/resources/graphql.for.umbraco.api.resource.js',
46+
'source/controllers/dashboard.controller.js'
47+
],
48+
dest: '<%= basePath %>/js/graphql.for.umbraco.js'
49+
}
50+
},
51+
52+
copy: {
53+
html: {
54+
cwd: 'source/views/',
55+
src: [
56+
'dashboard.html'
57+
],
58+
dest: '<%= basePath %>/views/',
59+
expand: true,
60+
rename: function(dest, src) {
61+
return dest + src;
62+
}
63+
},
64+
css: {
65+
cwd: 'source/css/',
66+
src: [
67+
'graphql.for.umbraco.css'
68+
],
69+
dest: '<%= basePath %>/css/',
70+
expand: true,
71+
rename: function(dest, src) {
72+
return dest + src;
73+
}
74+
},
75+
manifest: {
76+
cwd: 'source/',
77+
src: [
78+
'package.manifest'
79+
],
80+
dest: '<%= basePath %>/',
81+
expand: true,
82+
rename: function(dest, src) {
83+
return dest + src;
84+
}
85+
},
86+
umbraco: {
87+
cwd: '<%= dest %>',
88+
src: '**/*',
89+
dest: 'tmp/umbraco',
90+
expand: true
91+
}
92+
},
93+
94+
umbracoPackage: {
95+
dist: {
96+
src: 'tmp/umbraco',
97+
dest: 'pkg',
98+
options: {
99+
name: "<%= pkgMeta.name %>",
100+
version: '<%= pkgMeta.version %>',
101+
url: '<%= pkgMeta.url %>',
102+
license: '<%= pkgMeta.license %>',
103+
licenseUrl: '<%= pkgMeta.licenseUrl %>',
104+
author: '<%= pkgMeta.author %>',
105+
authorUrl: '<%= pkgMeta.authorUrl %>',
106+
manifest: 'config/package.xml',
107+
readme: '<%= grunt.file.read("config/readme.txt") %>',
108+
}
109+
}
110+
},
111+
112+
jshint: {
113+
options: {
114+
jshintrc: '.jshintrc'
115+
},
116+
src: {
117+
src: ['app/**/*.js', 'lib/**/*.js']
118+
}
119+
},
120+
121+
sass: {
122+
dist: {
123+
options: {
124+
style: 'compressed'
125+
},
126+
files: {
127+
'source/css/graphql.for.umbraco.css': 'source/sass/graphql.for.umbraco.scss'
128+
}
129+
}
130+
},
131+
132+
clean: {
133+
build: '<%= grunt.config("basePath").substring(0, 4) == "dist" ? "dist/**/*" : "null" %>',
134+
tmp: ['tmp'],
135+
html: [
136+
'source/views/*.html',
137+
'!source/views/dashboard.html'
138+
],
139+
js: [
140+
'source/controllers/*.js',
141+
'!source/resources/graphql.for.umbraco.api.resource.js',
142+
'!source/controllers/dashboard.controller.js'
143+
],
144+
css: [
145+
'source/css/*.css',
146+
'!source/css/graphql.for.umbraco.css'
147+
],
148+
sass: [
149+
'source/sass/*.scss',
150+
'!source/sass/graphql.for.umbraco.scss'
151+
]
152+
},
153+
});
154+
155+
grunt.registerTask('default', ['concat', 'sass:dist', 'copy:html', 'copy:manifest', 'copy:css', 'clean:html', 'clean:js', 'clean:css']);
156+
grunt.registerTask('umbraco', ['clean:tmp', 'default', 'copy:umbraco', 'umbracoPackage', 'clean:tmp']);
157+
};
158+
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"name": "GraphQLForUmbraco",
3+
"version": "0.0.1",
4+
"url": "https://github.com/rasmusjp/umbraco-graphql",
5+
"author": "Rasmus John Pedersen - Offroadcode - Kyle Weems - Jack Penney - Pete Duncanson - Et. Al.",
6+
"authorUrl": "https://github.com/rasmusjp/umbraco-graphql",
7+
"license": "MIT",
8+
"licenseUrl": "http://opensource.org/licenses/MIT"
9+
}
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2+
<umbPackage>
3+
<info>
4+
<package>
5+
<name><%= name %></name>
6+
<version><%= version %></version>
7+
<license url="<%= licenseUrl %>"><%= license %></license>
8+
<url><%= url %></url>
9+
<requirements>
10+
<major>0</major>
11+
<minor>0</minor>
12+
<patch>0</patch>
13+
</requirements>
14+
</package>
15+
<author>
16+
<name><%= author %></name>
17+
<website><%= authorUrl %></website>
18+
</author>
19+
<readme><![CDATA[<%= readme %>]]></readme>
20+
</info>
21+
<DocumentTypes />
22+
<Templates />
23+
<Stylesheets />
24+
<Macros />
25+
<DictionaryItems />
26+
<Languages />
27+
<DataTypes />
28+
<control />
29+
<Actions>
30+
<Action
31+
runat="install"
32+
alias="addDashboardSection"
33+
dashboardAlias="GraphQL.for.Umbraco.Dashboard"
34+
>
35+
<section>
36+
<areas>
37+
<area>developer</area>
38+
</areas>
39+
<tab caption="GraphQL for Umbraco">
40+
<control>/App_Plugins/GraphQLForUmbraco/views/dashboard.html</control>
41+
</tab>
42+
</section>
43+
</Action>
44+
</Actions>
45+
<files>
46+
<% files.forEach(function(file) { %>
47+
<file>
48+
<guid><%= file.guid %></guid>
49+
<orgPath><%= file.dir %></orgPath>
50+
<orgName><%= file.name %></orgName>
51+
</file>
52+
<% }); %>
53+
</files>
54+
</umbPackage>
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
For more info or to log issues visit https://github.com/rasmusjp/umbraco-graphql.

0 commit comments

Comments
 (0)