Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .jshintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"curly" : true,
"eqeqeq" : true,
"immed" : true,
"latedef" : true,
"newcap" : true,
"noarg" : true,
"sub" : true,
"undef" : true,
"boss" : true,
"eqnull" : true,
"node" : true,
"es5" : false,
"globals" : {
"it" : false,
"xit" : false,
"describe" : false,
"xdescribe" : false,
"beforeEach" : false,
"afterEach" : false,
"expect" : false,
"spyOn" : false
}
}
16 changes: 14 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,12 @@ language: php

# Declare versions of PHP to use. Use one decimal max.
php:
# aliased to a recent 7.0.x version
- "7.0"
# aliased to a recent 5.6.x version
- "5.6"
# aliased to a recent 5.5.x version
# "5.5"
- "5.5"
# aliased to a recent 5.4.x version
- "5.4"
# aliased to a recent 5.3.x version
Expand All @@ -26,6 +30,10 @@ env:
# @link https://github.com/WordPress/WordPress
# WP_VERSION=master WP_MULTISITE=0
# WP_VERSION=master WP_MULTISITE=1
# WordPress 4.6
# @link https://github.com/WordPress/WordPress/tree/4.6-branch
# WP_VERSION=4.6 WP_MULTISITE=0
- WP_VERSION=4.6 WP_MULTISITE=1
# WordPress 4.5
# @link https://github.com/WordPress/WordPress/tree/4.5-branch
# WP_VERSION=4.5 WP_MULTISITE=0
Expand All @@ -41,7 +49,11 @@ env:
matrix:
allow_failures:
- php: "5.4"
- env: WP_VERSION=4.5 WP_MULTISITE=1
- php: "5.5"
- php: "5.6"
- php: "7.0"
- env: "WP_VERSION=4.5 WP_MULTISITE=1"
- env: "WP_VERSION=4.6 WP_MULTISITE=1"
fast_finish: true

# Use this to prepare the system to install prerequisites or dependencies.
Expand Down
6 changes: 4 additions & 2 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,15 @@ module.exports = function(grunt) {
require('load-grunt-tasks')(grunt);

// There are basically three phases of building the production theme:
// 0) Testing / linting
grunt.registerTask('test', ['jshint', 'jasmine']);
// 1) Javascript preparation (concatenating and uglifying scripts)
// (coming soon)
grunt.registerTask('javascript', ['uglify']);
// 2) Stylesheet preparation (SASS, autoprefixing, and minification)
// (coming soon)
// 3) Appending the most recent git commit to the theme version
grunt.registerTask('release', ['gitinfo', 'replace']);
// The default task performs all three phases.
grunt.registerTask('default', ['release']);
grunt.registerTask('default', ['test', 'javascript', 'release']);

};
2 changes: 1 addition & 1 deletion additionalPosts-biblio.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
</script>


<?php } // Removes button end. ?>
<?php } ?>



Expand Down
6 changes: 2 additions & 4 deletions additionalPosts-cat.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,7 @@
<script>
$("#another").hide();
</script>
<?php }
// Removes button end.
?>
<?php } ?>

<?php if ( $the_query->have_posts() ) : ?>

Expand All @@ -86,7 +84,7 @@

<?php if ( get_post_type( get_the_ID() ) == 'bibliotech' ) { ?>

<?php } //get_post_type( get_the_ID() ) == 'bibliotech' ?>
<?php } ?>

<?php wp_reset_query(); // Restore global post data stomped by the_post(). ?>

Expand Down
2 changes: 1 addition & 1 deletion additionalPosts-search.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ function set_search( $q ) {
if ( 'search' == $query_split[0] ) {
$search_args['s'] = urldecode( $query_split[1] );
}
} // foreach
}

$the_query = new WP_Query( $search_args );
// The set_search() function is defined above.
Expand Down
13 changes: 5 additions & 8 deletions archive.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,20 @@
get_header();
$date = DateTime::createFromFormat( 'Ymd', get_field( 'event_date' ) );

get_template_part( 'inc/sub-header' );

if ( (get_post_type( get_the_ID() ) === 'bibliotech') || (cat_is_ancestor_of( 73, $cat ) or is_category( 73 )) ) {
get_template_part( 'inc/bib-header' );
}
?>
<?php get_template_part( 'inc/sub-header' ); ?>
<?php
if ( (get_post_type( get_the_ID() ) == 'bibliotech') || (cat_is_ancestor_of( 73, $cat ) or is_category( 73 )) ) { ?>
<?php get_template_part( 'inc/bib-header' ); ?>
<?php } ?>



<section id="" class="site-content">
<div id="content" role="main">
<?php if ( have_posts() ) : ?>

<!-- .archive-header -->
<div class="container">
<div class="row">
<div class="row" id="mitlibnews-container" data-postcontent="issue" data-postissue="<?php echo esc_attr( get_queried_object()->slug ); ?>">


<?php
Expand Down
2 changes: 1 addition & 1 deletion author.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
<?php /* Start the Loop
*/
?>
<div class="row">
<div class="row" id="mitlibnews-container" data-postcontent="author" data-postauthor="<?php the_author_id(); ?>">



Expand Down
6 changes: 2 additions & 4 deletions category.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@

get_header();



$date = DateTime::createFromFormat( 'Ymd', get_field( 'event_date' ) );
?>
<?php get_template_part( 'inc/sub-header' ); ?>
Expand All @@ -18,7 +16,7 @@
<div id="content" role="main">
<?php if ( have_posts() ) : ?>
<div class="container container-fluid">
<div class="row">
<div class="row" id="mitlibnews-container" data-postcontent="category" data-postcategory="<?php echo esc_attr( get_query_var( 'cat' ) ); ?>">
<?php
if ( is_category() ) {
printf( '<h1 class="lib-header">' . 'Category: ' . '<strong>' . single_cat_title( '', false ) . '</strong>' . '</h1>' );
Expand All @@ -33,7 +31,7 @@

<?php if ( get_post_type( get_the_ID() ) == 'bibliotech' ) { ?>

<?php } //get_post_type( get_the_ID() ) == 'bibliotech' ?>
<?php } ?>

<?php wp_reset_query(); // Restore global post data stomped by the_post(). ?>

Expand Down
2 changes: 2 additions & 0 deletions codesniffer.ruleset.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
<exclude name="Generic.WhiteSpace.ScopeIndent.IncorrectExact" />
<exclude name="Generic.WhiteSpace.ScopeIndent.Incorrect" />
<exclude name="PEAR.Functions.FunctionCallSignature.Indent" />
<exclude name="Squiz.Commenting.LongConditionClosingComment.Invalid" />
<exclude name="Squiz.Commenting.LongConditionClosingComment.Missing" />
<!-- Exclude the following known-failing sniffs -->
<exclude name="Generic.CodeAnalysis.EmptyStatement.DetectedELSE" />
<exclude name="Generic.Files.LineEndings.InvalidEOLChar" />
Expand Down
2 changes: 1 addition & 1 deletion css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Description: A Wordpress child theme that descends from mitlibraries-parent
Author: Design by Moth Design, development by MIT Libraries
Template: libraries
Version: 1.5.0-@@branch-@@commit;
Version: 2.0.0-@@branch-@@commit;
*/

@import url("../libraries/style.css");
Expand Down
Loading