Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bootstrap
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
bootstrap
Commits
6c2fa943
Commit
6c2fa943
authored
Jul 22, 2012
by
Jacob Thornton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add haunt w/ issue guideline spec
parent
b9105b98
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
92 additions
and
0 deletions
+92
-0
.issue-guidelines.js
.issue-guidelines.js
+85
-0
Makefile
Makefile
+7
-0
No files found.
.issue-guidelines.js
0 → 100644
View file @
6c2fa943
/* ==========================================================
* issue-guidelines.js
* http://twitter.github.com/bootstrap/javascript.html#alerts
* ==========================================================
* Copyright 2012 Twitter, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* ========================================================== */
var
assert
=
require
(
'
assert
'
)
module
.
exports
=
{
'
pull-requests
'
:
{
'
should always be made against -wip branches
'
:
function
(
pull
)
{
assert
.
ok
(
/
\-
wip$/
.
test
(
pull
.
base
.
label
))
},
'
should always be made from feature branches
'
:
function
(
pull
)
{
assert
.
ok
(
pull
.
head
.
label
!=
'
master
'
)
},
'
should always include a unit test if changing js files
'
:
function
(
pull
)
{
var
hasJS
=
false
var
hasTests
=
false
pull
.
files
.
forEach
(
function
(
file
)
{
if
(
/^js
\/[^
.
/]
+.js/
.
test
(
file
.
filename
))
hasJS
=
true
if
(
/^js
\/
test
\/
unit
\/[^
.
]
+.js/
.
test
(
file
.
filename
))
hasTests
=
true
})
assert
.
ok
(
!
hasJS
||
hasJS
&&
hasTests
)
},
'
after
'
:
function
(
pull
)
{
if
(
pull
.
reporter
.
stats
.
failures
)
{
pull
.
reportFailures
(
pull
.
close
.
bind
(
pull
))
}
}
},
'
issues
'
:
{
'
before
'
:
function
(
issue
)
{
var
plus
=
{}
var
labels
=
issue
.
labels
.
map
(
function
(
label
)
{
return
label
.
name
});
if
(
~
labels
.
indexOf
(
'
popular
'
))
return
issue
.
comments
.
forEach
(
function
(
comment
)
{
if
(
/
\+
1/
.
test
(
comment
.
body
))
plus
[
comment
.
user
.
login
]
=
true
})
if
(
Object
.
keys
(
plus
).
length
>
5
)
{
issue
.
tag
(
'
popular
'
)
issue
.
comment
(
'
Tagging this issue as popular, please stop commenting on this issue with +1. thanks!
'
)
}
},
'
should include a jsfiddle/jsbin illustrating the problem if tagged with js but not a feature
'
:
function
(
issue
)
{
var
labels
=
issue
.
labels
.
map
(
function
(
label
)
{
return
label
.
name
});
if
(
~
labels
.
indexOf
(
'
js
'
)
&&
!~
labels
.
indexOf
(
'
feature
'
))
assert
.
ok
(
/
(
jsfiddle|jsbin
)
/
.
test
(
issue
.
body
))
},
'
after
'
:
function
(
issue
)
{
if
(
issue
.
reporter
.
stats
.
failures
)
{
issue
.
reportFailures
(
issue
.
close
.
bind
(
issue
))
}
}
}
}
\ No newline at end of file
Makefile
View file @
6c2fa943
...
...
@@ -90,5 +90,12 @@ watch:
echo
"Watching less files..."
;
\
watchr
-e
"watch('less/.*
\.
less') { system 'make' }"
#
# HAUNT GITHUB ISSUES 4 FAT & MDO ONLY (O_O )
#
haunt
:
@
haunt
-s
.issue-guidelines.js https://github.com/twitter/bootstrap
.PHONY
:
docs watch gh-pages
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment