cassanof/CommitMessageBackwards
Text Generation
•
Updated
•
27
•
4
commit
stringlengths 40
40
| old_file
stringlengths 4
237
| new_file
stringlengths 4
237
| old_contents
stringlengths 1
4.24k
| new_contents
stringlengths 5
4.84k
| subject
stringlengths 15
778
| message
stringlengths 16
6.86k
| lang
stringlengths 1
30
| license
stringclasses 13
values | repos
stringlengths 5
116k
| config
stringlengths 1
30
| content
stringlengths 105
8.72k
|
---|---|---|---|---|---|---|---|---|---|---|---|
6c41c07f14c6042d054300af946f02f6ff90a87c | trex/static/js/services.js | trex/static/js/services.js | // -*- coding: utf-8 -*-
//
// (c) 2014 Bjoern Ricks <bjoern.ricks@gmail.com>
//
// See LICENSE comming with the source of 'trex' for details.
//
'use strict';
var trexServices = angular.module('trex.services', ['ngResource']);
trexServices.factory('Conf', function($location) {
function getRootUrl() {
var rootUrl = $location.protocol() + '://' + $location.host();
if ($location.port())
rootUrl += ':' + $location.port();
return rootUrl;
};
return {
'apiBase': '/api/1',
'rootUrl': getRootUrl()
};
});
trexServices.factory('Project', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/projects/:projectId',
{projectId: '@id'},
{entries: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/entries',
params: {projectId: '@id'}
},
tags: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/tags',
params: {projectId: '@id'}
}
}
);
}
]);
trexServices.factory('Entry', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/entries/:entryId', {entryId: '@id'}, {
});
}
]);
| // -*- coding: utf-8 -*-
//
// (c) 2014 Bjoern Ricks <bjoern.ricks@gmail.com>
//
// See LICENSE comming with the source of 'trex' for details.
//
'use strict';
var trexServices = angular.module('trex.services', ['ngResource']);
trexServices.factory('Conf', function($location) {
function getRootUrl() {
var rootUrl = $location.protocol() + '://' + $location.host();
if ($location.port())
rootUrl += ':' + $location.port();
return rootUrl;
};
return {
'apiBase': '/api/1',
'rootUrl': getRootUrl()
};
});
trexServices.factory('Project', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/projects/:projectId',
{projectId: '@id'},
{entries: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/entries',
params: {projectId: '@id'}
},
tags: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/tags',
params: {projectId: '@id'}
},
users: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/users',
params: {projectId: '@id'}
}
}
);
}
]);
trexServices.factory('Entry', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/entries/:entryId', {entryId: '@id'}, {
});
}
]);
| Add users to Project angular ressource | Add users to Project angular ressource
| JavaScript | mit | bjoernricks/trex,bjoernricks/trex | javascript | ## Code Before:
// -*- coding: utf-8 -*-
//
// (c) 2014 Bjoern Ricks <bjoern.ricks@gmail.com>
//
// See LICENSE comming with the source of 'trex' for details.
//
'use strict';
var trexServices = angular.module('trex.services', ['ngResource']);
trexServices.factory('Conf', function($location) {
function getRootUrl() {
var rootUrl = $location.protocol() + '://' + $location.host();
if ($location.port())
rootUrl += ':' + $location.port();
return rootUrl;
};
return {
'apiBase': '/api/1',
'rootUrl': getRootUrl()
};
});
trexServices.factory('Project', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/projects/:projectId',
{projectId: '@id'},
{entries: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/entries',
params: {projectId: '@id'}
},
tags: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/tags',
params: {projectId: '@id'}
}
}
);
}
]);
trexServices.factory('Entry', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/entries/:entryId', {entryId: '@id'}, {
});
}
]);
## Instruction:
Add users to Project angular ressource
## Code After:
// -*- coding: utf-8 -*-
//
// (c) 2014 Bjoern Ricks <bjoern.ricks@gmail.com>
//
// See LICENSE comming with the source of 'trex' for details.
//
'use strict';
var trexServices = angular.module('trex.services', ['ngResource']);
trexServices.factory('Conf', function($location) {
function getRootUrl() {
var rootUrl = $location.protocol() + '://' + $location.host();
if ($location.port())
rootUrl += ':' + $location.port();
return rootUrl;
};
return {
'apiBase': '/api/1',
'rootUrl': getRootUrl()
};
});
trexServices.factory('Project', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/projects/:projectId',
{projectId: '@id'},
{entries: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/entries',
params: {projectId: '@id'}
},
tags: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/tags',
params: {projectId: '@id'}
},
users: {method: 'GET', isArray: true,
url: Conf.apiBase + '/projects/:projectId/users',
params: {projectId: '@id'}
}
}
);
}
]);
trexServices.factory('Entry', ['$resource', 'Conf',
function($resource, Conf) {
return $resource(Conf.apiBase + '/entries/:entryId', {entryId: '@id'}, {
});
}
]);
|
9385f2be12a4042417f7930971af533b44c73ea0 | code/parallel_make.bash | code/parallel_make.bash | MAIN_TARGET=$1
LINES=$2
> $MAIN_TARGET.temp
TARGETS=$(make print-$MAIN_TARGET | sed 's/HE_AN_LIST=//g')
for T in $TARGETS
do
echo make $T >> $MAIN_TARGET.temp
done
split -l $LINES $MAIN_TARGET.temp
for X in x??
do
cat head.batch $X tail.batch > $X.qsub
qsub $X.qsub
rm $X.qsub $X
done
rm $MAIN_TARGET.temp
| MAIN_TARGET=$1
LINES=$2
> $MAIN_TARGET.temp
TARGETS=$(make print-$MAIN_TARGET | sed 's/.*=//g')
for T in $TARGETS
do
echo make $T >> $MAIN_TARGET.temp
done
split -l $LINES $MAIN_TARGET.temp
for X in x??
do
cat head.batch $X tail.batch > $X.qsub
qsub $X.qsub
rm $X.qsub $X
done
rm $MAIN_TARGET.temp
| Generalize to other types of targets | Generalize to other types of targets
| Shell | mit | SchlossLab/Schloss_Cluster_PeerJ_2015,zhwcoder/Schloss_Cluster_PeerJ_2015,SchlossLab/Schloss_Cluster_PeerJ_2015,SchlossLab/Schloss_Cluster_PeerJ_2015,zhwcoder/Schloss_Cluster_PeerJ_2015 | shell | ## Code Before:
MAIN_TARGET=$1
LINES=$2
> $MAIN_TARGET.temp
TARGETS=$(make print-$MAIN_TARGET | sed 's/HE_AN_LIST=//g')
for T in $TARGETS
do
echo make $T >> $MAIN_TARGET.temp
done
split -l $LINES $MAIN_TARGET.temp
for X in x??
do
cat head.batch $X tail.batch > $X.qsub
qsub $X.qsub
rm $X.qsub $X
done
rm $MAIN_TARGET.temp
## Instruction:
Generalize to other types of targets
## Code After:
MAIN_TARGET=$1
LINES=$2
> $MAIN_TARGET.temp
TARGETS=$(make print-$MAIN_TARGET | sed 's/.*=//g')
for T in $TARGETS
do
echo make $T >> $MAIN_TARGET.temp
done
split -l $LINES $MAIN_TARGET.temp
for X in x??
do
cat head.batch $X tail.batch > $X.qsub
qsub $X.qsub
rm $X.qsub $X
done
rm $MAIN_TARGET.temp
|
3edab176373cd2d07e722b89a4e4ca30e26fe7ac | Setup/InstallSchema.php | Setup/InstallSchema.php | <?php
/**
* Raguvis CmsNavigation
*/
namespace Raguvis\CmsNavigation\Setup;
use Magento\Framework\Setup\InstallSchemaInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\SchemaSetupInterface;
class InstallSchema implements InstallSchemaInterface
{
/**
* Add Include in navigation flag
*/
public function install(SchemaSetupInterface $setup, ModuleContextInterface $context)
{
$installer = $setup;
$installer->startSetup();
$setup->getConnection()->addColumn(
$setup->getTable('cms_page'),
'show_in_navigation',
[
'type' => \Magento\Framework\DB\Ddl\Table::TYPE_BOOLEAN,
'nullable' => false,
'comment' => 'Flag whether or not CMS page should be included in top navigation'
]
);
$installer->endSetup();
}
} | <?php
/**
* Raguvis CmsNavigation
*/
namespace Raguvis\CmsNavigation\Setup;
use Magento\Framework\Setup\InstallSchemaInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\SchemaSetupInterface;
class InstallSchema implements InstallSchemaInterface
{
/**
* Add Include in navigation flag
*/
public function install(SchemaSetupInterface $setup, ModuleContextInterface $context)
{
$installer = $setup;
$installer->startSetup();
$setup->getConnection()->addColumn(
$setup->getTable('cms_page'),
'show_in_navigation',
[
'type' => \Magento\Framework\DB\Ddl\Table::TYPE_BOOLEAN,
'nullable' => false,
'comment' => 'Flag whether or not CMS page should be included in top navigation',
'default' => 0
]
);
$installer->endSetup();
}
}
| Fix cms_page field to have default value | Fix cms_page field to have default value
Otherwise when cms page is added via code it will fail with error 'Integrity constraint violation: 1048 Column 'show_in_navigation' cannot be null' | PHP | mit | valdemaras-zilys/magento2-CmsNavigation | php | ## Code Before:
<?php
/**
* Raguvis CmsNavigation
*/
namespace Raguvis\CmsNavigation\Setup;
use Magento\Framework\Setup\InstallSchemaInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\SchemaSetupInterface;
class InstallSchema implements InstallSchemaInterface
{
/**
* Add Include in navigation flag
*/
public function install(SchemaSetupInterface $setup, ModuleContextInterface $context)
{
$installer = $setup;
$installer->startSetup();
$setup->getConnection()->addColumn(
$setup->getTable('cms_page'),
'show_in_navigation',
[
'type' => \Magento\Framework\DB\Ddl\Table::TYPE_BOOLEAN,
'nullable' => false,
'comment' => 'Flag whether or not CMS page should be included in top navigation'
]
);
$installer->endSetup();
}
}
## Instruction:
Fix cms_page field to have default value
Otherwise when cms page is added via code it will fail with error 'Integrity constraint violation: 1048 Column 'show_in_navigation' cannot be null'
## Code After:
<?php
/**
* Raguvis CmsNavigation
*/
namespace Raguvis\CmsNavigation\Setup;
use Magento\Framework\Setup\InstallSchemaInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\SchemaSetupInterface;
class InstallSchema implements InstallSchemaInterface
{
/**
* Add Include in navigation flag
*/
public function install(SchemaSetupInterface $setup, ModuleContextInterface $context)
{
$installer = $setup;
$installer->startSetup();
$setup->getConnection()->addColumn(
$setup->getTable('cms_page'),
'show_in_navigation',
[
'type' => \Magento\Framework\DB\Ddl\Table::TYPE_BOOLEAN,
'nullable' => false,
'comment' => 'Flag whether or not CMS page should be included in top navigation',
'default' => 0
]
);
$installer->endSetup();
}
}
|
6cf484c9a3ce5aa141363ae67c58fa94d055a105 | app/assets/javascripts/app/views/bookmarklet_view.js | app/assets/javascripts/app/views/bookmarklet_view.js | app.views.Bookmarklet = Backbone.View.extend({
separator: ' - ',
initialize: function(opts) {
// init a standalone publisher
app.publisher = new app.views.Publisher({standalone: true});
app.publisher.on('publisher:add', this._postSubmit, this);
app.publisher.on('publisher:sync', this._postSuccess, this);
app.publisher.on('publisher:error', this._postError, this);
this.param_contents = opts;
},
render: function() {
app.publisher.open();
app.publisher.setText(this._publisherContent());
return this;
},
_publisherContent: function() {
var p = this.param_contents;
if( p.content ) return p.content;
var contents = p.title + this.separator + p.url;
if( p.notes ) contents += this.separator + p.notes;
return contents;
},
_postSubmit: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_submit'));
},
_postSuccess: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_success'));
app.publisher.close();
_.delay(window.close, 2000);
},
_postError: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_error'));
}
});
| app.views.Bookmarklet = Backbone.View.extend({
separator: ' - ',
initialize: function(opts) {
// init a standalone publisher
app.publisher = new app.views.Publisher({standalone: true});
app.publisher.on('publisher:add', this._postSubmit, this);
app.publisher.on('publisher:sync', this._postSuccess, this);
app.publisher.on('publisher:error', this._postError, this);
this.param_contents = opts;
},
render: function() {
app.publisher.open();
app.publisher.setText(this._publisherContent());
return this;
},
_publisherContent: function() {
var p = this.param_contents;
if( p.content ) return p.content;
var contents = p.title + this.separator + p.url;
if( p.notes ) contents += this.separator + p.notes;
return contents;
},
_postSubmit: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_submit'));
},
_postSuccess: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_success'));
app.publisher.close();
this.$("#publisher").addClass("hidden");
_.delay(window.close, 2000);
},
_postError: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_error'));
}
});
| Make sure publisher is totally hidden in bookmarklet after post success | Make sure publisher is totally hidden in bookmarklet after post success
| JavaScript | agpl-3.0 | geraspora/diaspora,jhass/diaspora,Flaburgan/diaspora,diaspora/diaspora,Amadren/diaspora,diaspora/diaspora,geraspora/diaspora,despora/diaspora,Amadren/diaspora,Amadren/diaspora,Muhannes/diaspora,SuperTux88/diaspora,jhass/diaspora,KentShikama/diaspora,spixi/diaspora,jhass/diaspora,SuperTux88/diaspora,SuperTux88/diaspora,SuperTux88/diaspora,Muhannes/diaspora,Muhannes/diaspora,KentShikama/diaspora,geraspora/diaspora,despora/diaspora,spixi/diaspora,geraspora/diaspora,Muhannes/diaspora,Amadren/diaspora,despora/diaspora,diaspora/diaspora,diaspora/diaspora,Flaburgan/diaspora,KentShikama/diaspora,KentShikama/diaspora,despora/diaspora,spixi/diaspora,jhass/diaspora,spixi/diaspora,Flaburgan/diaspora,Flaburgan/diaspora | javascript | ## Code Before:
app.views.Bookmarklet = Backbone.View.extend({
separator: ' - ',
initialize: function(opts) {
// init a standalone publisher
app.publisher = new app.views.Publisher({standalone: true});
app.publisher.on('publisher:add', this._postSubmit, this);
app.publisher.on('publisher:sync', this._postSuccess, this);
app.publisher.on('publisher:error', this._postError, this);
this.param_contents = opts;
},
render: function() {
app.publisher.open();
app.publisher.setText(this._publisherContent());
return this;
},
_publisherContent: function() {
var p = this.param_contents;
if( p.content ) return p.content;
var contents = p.title + this.separator + p.url;
if( p.notes ) contents += this.separator + p.notes;
return contents;
},
_postSubmit: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_submit'));
},
_postSuccess: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_success'));
app.publisher.close();
_.delay(window.close, 2000);
},
_postError: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_error'));
}
});
## Instruction:
Make sure publisher is totally hidden in bookmarklet after post success
## Code After:
app.views.Bookmarklet = Backbone.View.extend({
separator: ' - ',
initialize: function(opts) {
// init a standalone publisher
app.publisher = new app.views.Publisher({standalone: true});
app.publisher.on('publisher:add', this._postSubmit, this);
app.publisher.on('publisher:sync', this._postSuccess, this);
app.publisher.on('publisher:error', this._postError, this);
this.param_contents = opts;
},
render: function() {
app.publisher.open();
app.publisher.setText(this._publisherContent());
return this;
},
_publisherContent: function() {
var p = this.param_contents;
if( p.content ) return p.content;
var contents = p.title + this.separator + p.url;
if( p.notes ) contents += this.separator + p.notes;
return contents;
},
_postSubmit: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_submit'));
},
_postSuccess: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_success'));
app.publisher.close();
this.$("#publisher").addClass("hidden");
_.delay(window.close, 2000);
},
_postError: function(evt) {
this.$('h4').text(Diaspora.I18n.t('bookmarklet.post_error'));
}
});
|
3599eb16dbe856a31d1ce7a58cdd3b7b26c502f3 | lib/relax/helpers.rb | lib/relax/helpers.rb | module Relax
module Helpers
def relax_tag
if defined?(@relax) && @relax
"<script type='text/javascript'>Relax.replace(#{@relax});</script>".html_safe
end
end
def relax_snippet
if defined?(@relax) && @relax
"Relax.replace(#{@relax});".html_safe
end
end
def use_relax_html
@_use_relax_html = true
end
def relax_silient?
!!request.headers["X-SILENT"]
end
def relax_filter
request.params[:_relax_filter] || (session && session[:relax_filter])
end
end
end
| module Relax
module Helpers
def relax_tag
if defined?(@relax) && @relax
"<script type='text/javascript'>Relax.replace(#{@relax});</script>".html_safe
end
end
def relax_snippet
if defined?(@relax) && @relax
snippet = @relax.gsub(/\;$/, '')
"Relax.replace(#{snippet});".html_safe
end
end
def use_relax_html
@_use_relax_html = true
end
def relax_silient?
!!request.headers["X-SILENT"]
end
def relax_filter
request.params[:_relax_filter] || (session && session[:relax_filter])
end
end
end
| Fix ie11 can't have semicolons inside parenthesis | Fix ie11 can't have semicolons inside parenthesis
| Ruby | mit | jho406/Breezy,jho406/Relax,jho406/Relax,jho406/Breezy,jho406/Relax,jho406/Breezy | ruby | ## Code Before:
module Relax
module Helpers
def relax_tag
if defined?(@relax) && @relax
"<script type='text/javascript'>Relax.replace(#{@relax});</script>".html_safe
end
end
def relax_snippet
if defined?(@relax) && @relax
"Relax.replace(#{@relax});".html_safe
end
end
def use_relax_html
@_use_relax_html = true
end
def relax_silient?
!!request.headers["X-SILENT"]
end
def relax_filter
request.params[:_relax_filter] || (session && session[:relax_filter])
end
end
end
## Instruction:
Fix ie11 can't have semicolons inside parenthesis
## Code After:
module Relax
module Helpers
def relax_tag
if defined?(@relax) && @relax
"<script type='text/javascript'>Relax.replace(#{@relax});</script>".html_safe
end
end
def relax_snippet
if defined?(@relax) && @relax
snippet = @relax.gsub(/\;$/, '')
"Relax.replace(#{snippet});".html_safe
end
end
def use_relax_html
@_use_relax_html = true
end
def relax_silient?
!!request.headers["X-SILENT"]
end
def relax_filter
request.params[:_relax_filter] || (session && session[:relax_filter])
end
end
end
|
28a9e730b076ca598162a7699380ce3fb2b47095 | .travis.yml | .travis.yml | language: python
python:
- "3.6"
cache:
pip: true
directories:
- $HOME/.gimme
- $HOME/.imageio
before_install:
- gimme 1.6
- export GOROOT="$HOME/.gimme/versions/go1.6.linux.amd64"
- export GOPATH="$HOME/.gimme/versions/go1.6.linux.amd64/bin:$TRAVIS_BUILD_DIR"
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/discordgo
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/dgvoice
script:
- cd Discord
- python Harmonbot.py
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go run Harmonbot_Listener.go
- python ../Telegram/Telegram_Harmonbot.py
| language: python
# python:
# - "3.7"
# Workaround for Python 3.7
# https://github.com/travis-ci/travis-ci/issues/9815
matrix:
include:
- python: 3.7
dist: xenial
sudo: true
cache:
pip: true
directories:
- $HOME/.gimme
- $HOME/.imageio
before_install:
- gimme 1.6
- export GOROOT="$HOME/.gimme/versions/go1.6.linux.amd64"
- export GOPATH="$HOME/.gimme/versions/go1.6.linux.amd64/bin:$TRAVIS_BUILD_DIR"
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/discordgo
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/dgvoice
script:
- cd Discord
- python Harmonbot.py
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go run Harmonbot_Listener.go
- python ../Telegram/Telegram_Harmonbot.py
| Update Travis CI Python version to 3.7 using workaround | Update Travis CI Python version to 3.7 using workaround
https://github.com/travis-ci/travis-ci/issues/9815 | YAML | mit | Harmon758/Harmonbot,Harmon758/Harmonbot | yaml | ## Code Before:
language: python
python:
- "3.6"
cache:
pip: true
directories:
- $HOME/.gimme
- $HOME/.imageio
before_install:
- gimme 1.6
- export GOROOT="$HOME/.gimme/versions/go1.6.linux.amd64"
- export GOPATH="$HOME/.gimme/versions/go1.6.linux.amd64/bin:$TRAVIS_BUILD_DIR"
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/discordgo
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/dgvoice
script:
- cd Discord
- python Harmonbot.py
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go run Harmonbot_Listener.go
- python ../Telegram/Telegram_Harmonbot.py
## Instruction:
Update Travis CI Python version to 3.7 using workaround
https://github.com/travis-ci/travis-ci/issues/9815
## Code After:
language: python
# python:
# - "3.7"
# Workaround for Python 3.7
# https://github.com/travis-ci/travis-ci/issues/9815
matrix:
include:
- python: 3.7
dist: xenial
sudo: true
cache:
pip: true
directories:
- $HOME/.gimme
- $HOME/.imageio
before_install:
- gimme 1.6
- export GOROOT="$HOME/.gimme/versions/go1.6.linux.amd64"
- export GOPATH="$HOME/.gimme/versions/go1.6.linux.amd64/bin:$TRAVIS_BUILD_DIR"
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/discordgo
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go get github.com/bwmarrin/dgvoice
script:
- cd Discord
- python Harmonbot.py
- $HOME/.gimme/versions/go1.6.linux.amd64/bin/go run Harmonbot_Listener.go
- python ../Telegram/Telegram_Harmonbot.py
|
b29f8ce14633361681956201dfeef7007a46230f | bin/blueoak-server.js | bin/blueoak-server.js | /*
* Copyright (c) 2015-2016 PointSource, LLC.
* MIT Licensed
*/
var server = require('../');
server.init({
appDir: process.cwd()
}, function(err) {
if (err) {
console.warn('Startup failed', err);
} else {
console.log('started');
}
});
| /*
* Copyright (c) 2015-2016 PointSource, LLC.
* MIT Licensed
*/
var server = require('../');
server.init({
appDir: process.cwd()
}, function(err) {
if (err) {
console.warn('Startup failed', err);
} else {
var logger = this.services.get('logger');
logger.info('Server started');
}
});
| Make server launcher use logger for server startup message | Make server launcher use logger for server startup message
| JavaScript | mit | BlueOakJS/blueoak-server | javascript | ## Code Before:
/*
* Copyright (c) 2015-2016 PointSource, LLC.
* MIT Licensed
*/
var server = require('../');
server.init({
appDir: process.cwd()
}, function(err) {
if (err) {
console.warn('Startup failed', err);
} else {
console.log('started');
}
});
## Instruction:
Make server launcher use logger for server startup message
## Code After:
/*
* Copyright (c) 2015-2016 PointSource, LLC.
* MIT Licensed
*/
var server = require('../');
server.init({
appDir: process.cwd()
}, function(err) {
if (err) {
console.warn('Startup failed', err);
} else {
var logger = this.services.get('logger');
logger.info('Server started');
}
});
|
1012db43c5db570d7d896bfc9e13859c9428250c | app/components/legend-detail/template.hbs | app/components/legend-detail/template.hbs | <iframe src= {{legend.link}} width="300" height="480" frameborder="0" style="border:0" allowfullscreen></iframe> {{legend.legendName}}
<ul>
{{#each legend.reviews as |review|}}
{{review-tile review=review}}
<br>
on {{moment-format review.createdAt 'LLL'}}
{{/each}}
</ul>
| <iframe src= {{legend.link}} width="300" height="480" frameborder="0" style="border:0" allowfullscreen></iframe> {{legend.legendName}}
<ul>
{{#each legend.reviews as |review|}}
{{review-tile review=review}}
<small>
on {{moment-format review.createdAt 'LLL'}}
</small>
{{/each}}
</ul>
| Add Tag for Timestamp Put Timestamp in Small Tag to match author of the review | Add Tag for Timestamp
Put Timestamp in Small Tag to match author of the review
| Handlebars | mit | mwerumuchai/traffic-tracker,mwerumuchai/traffic-tracker | handlebars | ## Code Before:
<iframe src= {{legend.link}} width="300" height="480" frameborder="0" style="border:0" allowfullscreen></iframe> {{legend.legendName}}
<ul>
{{#each legend.reviews as |review|}}
{{review-tile review=review}}
<br>
on {{moment-format review.createdAt 'LLL'}}
{{/each}}
</ul>
## Instruction:
Add Tag for Timestamp
Put Timestamp in Small Tag to match author of the review
## Code After:
<iframe src= {{legend.link}} width="300" height="480" frameborder="0" style="border:0" allowfullscreen></iframe> {{legend.legendName}}
<ul>
{{#each legend.reviews as |review|}}
{{review-tile review=review}}
<small>
on {{moment-format review.createdAt 'LLL'}}
</small>
{{/each}}
</ul>
|
9bd1c4c18d76b8e785794d7ae7845f211b5cc5c7 | Slim/ResolveCallable.php | Slim/ResolveCallable.php | <?php
/**
* Slim Framework (http://slimframework.com)
*
* @link https://github.com/codeguy/Slim
* @copyright Copyright (c) 2011-2015 Josh Lockhart
* @license https://github.com/codeguy/Slim/blob/master/LICENSE (MIT License)
*/
namespace Slim;
use Interop\Container\ContainerInterface;
/**
* ResolveCallable
*
* This is an internal class that enables resolution of 'class:method' strings
* into a closure. This class is an implementation detail and is used only inside
* of the Slim application.
*/
trait ResolveCallable
{
/**
* Resolve a string of the format 'class:method' into a closure that the
* router can dispatch.
*
* @param string $callable
*
* @return \Closure
*/
protected function resolveCallable($callable)
{
if (is_string($callable) && strpos($callable, ':')) {
if ($this instanceof ContainerInterface) {
$container = $this;
} elseif ($this->container instanceof ContainerInterface) {
$container = $this->container;
} else {
throw new \RuntimeException('Cannot resolve callable string');
}
return new CallableResolver($callable, $container);
}
return $callable;
}
}
| <?php
/**
* Slim Framework (http://slimframework.com)
*
* @link https://github.com/codeguy/Slim
* @copyright Copyright (c) 2011-2015 Josh Lockhart
* @license https://github.com/codeguy/Slim/blob/master/LICENSE (MIT License)
*/
namespace Slim;
use Interop\Container\ContainerInterface;
/**
* ResolveCallable
*
* This is an internal class that enables resolution of 'class:method' strings
* into a closure. This class is an implementation detail and is used only inside
* of the Slim application.
*/
trait ResolveCallable
{
/**
* Resolve a string of the format 'class:method' into a closure that the
* router can dispatch.
*
* @param string $callable
*
* @return \Closure
*/
protected function resolveCallable($callable)
{
if (is_string($callable) && strpos($callable, ':')) {
if ($this->container instanceof ContainerInterface) {
$container = $this->container;
} else {
throw new \RuntimeException('Cannot resolve callable string');
}
return new CallableResolver($callable, $container);
}
return $callable;
}
}
| Tidy up resolveCallable() as $this is never an instance of ContainerInterface | Tidy up resolveCallable() as $this is never an instance of ContainerInterface
| PHP | mit | juliangut/Slim,iinux/Slim,akrabat/Slim,AndrewCarterUK/Slim,iinux/Slim,RealSelf/Slim,JoeBengalen/Slim,mnapoli/Slim,feryardiant/slim,Sam-Burns/Slim,slimphp/Slim,dopesong/Slim,samsonasik/Slim,jaapverloop/Slim,foxyantho/Slim,designermonkey/Slim,iinux/Slim,opengeek/Slim,somjit2514/basic | php | ## Code Before:
<?php
/**
* Slim Framework (http://slimframework.com)
*
* @link https://github.com/codeguy/Slim
* @copyright Copyright (c) 2011-2015 Josh Lockhart
* @license https://github.com/codeguy/Slim/blob/master/LICENSE (MIT License)
*/
namespace Slim;
use Interop\Container\ContainerInterface;
/**
* ResolveCallable
*
* This is an internal class that enables resolution of 'class:method' strings
* into a closure. This class is an implementation detail and is used only inside
* of the Slim application.
*/
trait ResolveCallable
{
/**
* Resolve a string of the format 'class:method' into a closure that the
* router can dispatch.
*
* @param string $callable
*
* @return \Closure
*/
protected function resolveCallable($callable)
{
if (is_string($callable) && strpos($callable, ':')) {
if ($this instanceof ContainerInterface) {
$container = $this;
} elseif ($this->container instanceof ContainerInterface) {
$container = $this->container;
} else {
throw new \RuntimeException('Cannot resolve callable string');
}
return new CallableResolver($callable, $container);
}
return $callable;
}
}
## Instruction:
Tidy up resolveCallable() as $this is never an instance of ContainerInterface
## Code After:
<?php
/**
* Slim Framework (http://slimframework.com)
*
* @link https://github.com/codeguy/Slim
* @copyright Copyright (c) 2011-2015 Josh Lockhart
* @license https://github.com/codeguy/Slim/blob/master/LICENSE (MIT License)
*/
namespace Slim;
use Interop\Container\ContainerInterface;
/**
* ResolveCallable
*
* This is an internal class that enables resolution of 'class:method' strings
* into a closure. This class is an implementation detail and is used only inside
* of the Slim application.
*/
trait ResolveCallable
{
/**
* Resolve a string of the format 'class:method' into a closure that the
* router can dispatch.
*
* @param string $callable
*
* @return \Closure
*/
protected function resolveCallable($callable)
{
if (is_string($callable) && strpos($callable, ':')) {
if ($this->container instanceof ContainerInterface) {
$container = $this->container;
} else {
throw new \RuntimeException('Cannot resolve callable string');
}
return new CallableResolver($callable, $container);
}
return $callable;
}
}
|
7cb98b8af5ddae7b967e19c906b282881b65b8b9 | stylesheets/heat_tamperenoise.css | stylesheets/heat_tamperenoise.css | html, body { height: 100%; padding: 0; margin: 0; }
#div1, #div2, #div3, #div4 { width: 50%; height: 50%; float: left; }
#div1 { background: #DDD; }
#div2 { background: #AAA; }
#div3 { background: #777; }
#div4 { background: #444; }
.feature_info {
padding: 6px 8px;
font: 24px/28px Arial, Helvetica, sans-serif;
background: white;
background: rgba(255,255,255,0.8);
box-shadow: 0 0 15px rgba(0,0,0,0.2);
border-radius: 2px;
}
| html, body { height: 100%; padding: 0; margin: 0; }
#div1, #div2, #div3, #div4 { float: left; }
#div1 { background: #DDD; width: 49.5%; height: 49.5%; }
#div2 { background: #AAA; width: 49.5%; height: 49.5%; margin-left: 1%; }
#div3 { background: #777; width: 49.5%; height: 49.5%; margin-top: 1%; }
#div4 { background: #444; width: 49.5%; height: 49.5%; margin-left: 1%; margin-top: 1%; }
.feature_info {
padding: 6px 8px;
font: 24px/28px Arial, Helvetica, sans-serif;
background: white;
background: rgba(255,255,255,0.8);
box-shadow: 0 0 15px rgba(0,0,0,0.2);
border-radius: 2px;
}
| Add small margin between maps | Add small margin between maps
| CSS | mit | ernoma/ernoma.github.io,ernoma/ernoma.github.io,ernoma/ernoma.github.io,ernoma/ernoma.github.io | css | ## Code Before:
html, body { height: 100%; padding: 0; margin: 0; }
#div1, #div2, #div3, #div4 { width: 50%; height: 50%; float: left; }
#div1 { background: #DDD; }
#div2 { background: #AAA; }
#div3 { background: #777; }
#div4 { background: #444; }
.feature_info {
padding: 6px 8px;
font: 24px/28px Arial, Helvetica, sans-serif;
background: white;
background: rgba(255,255,255,0.8);
box-shadow: 0 0 15px rgba(0,0,0,0.2);
border-radius: 2px;
}
## Instruction:
Add small margin between maps
## Code After:
html, body { height: 100%; padding: 0; margin: 0; }
#div1, #div2, #div3, #div4 { float: left; }
#div1 { background: #DDD; width: 49.5%; height: 49.5%; }
#div2 { background: #AAA; width: 49.5%; height: 49.5%; margin-left: 1%; }
#div3 { background: #777; width: 49.5%; height: 49.5%; margin-top: 1%; }
#div4 { background: #444; width: 49.5%; height: 49.5%; margin-left: 1%; margin-top: 1%; }
.feature_info {
padding: 6px 8px;
font: 24px/28px Arial, Helvetica, sans-serif;
background: white;
background: rgba(255,255,255,0.8);
box-shadow: 0 0 15px rgba(0,0,0,0.2);
border-radius: 2px;
}
|
f767b7051afee3fe494610d22b31e92d35493218 | examples/tas-server.go | examples/tas-server.go | package main
import (
"log"
"runtime"
)
import (
"github.com/chango/tas/tas"
)
func main() {
runtime.GOMAXPROCS(10)
tasConfig := tas.NewDefaultTASConfig()
svr, err := tas.NewTASServer(tasConfig)
if err != nil {
log.Println("Failed to start TAS: %s", err)
return
}
svr.Run()
}
| package main
import (
"log"
)
import (
"github.com/chango/tas/tas"
)
func main() {
tasConfig := tas.NewDefaultTASConfig()
svr, err := tas.NewTASServer(tasConfig)
if err != nil {
log.Println("Failed to start TAS:", err)
return
}
svr.Run()
}
| Remove runtime GOMAXPROCS from example and fix error print if TAS server cannot be created | Remove runtime GOMAXPROCS from example and fix error print if TAS server cannot be created
| Go | mit | oldmantaiter/tas,chango/tas,oldmantaiter/tas,chango/tas | go | ## Code Before:
package main
import (
"log"
"runtime"
)
import (
"github.com/chango/tas/tas"
)
func main() {
runtime.GOMAXPROCS(10)
tasConfig := tas.NewDefaultTASConfig()
svr, err := tas.NewTASServer(tasConfig)
if err != nil {
log.Println("Failed to start TAS: %s", err)
return
}
svr.Run()
}
## Instruction:
Remove runtime GOMAXPROCS from example and fix error print if TAS server cannot be created
## Code After:
package main
import (
"log"
)
import (
"github.com/chango/tas/tas"
)
func main() {
tasConfig := tas.NewDefaultTASConfig()
svr, err := tas.NewTASServer(tasConfig)
if err != nil {
log.Println("Failed to start TAS:", err)
return
}
svr.Run()
}
|
28d95e261ba5bdf94f480fe52b74b233005225e9 | .bazelci/build_bazel_binaries.yml | .bazelci/build_bazel_binaries.yml | ---
platforms:
centos7:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1604:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1804:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
macos:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
windows:
build_flags:
- "--copt=-w"
- "--host_copt=-w"
- "-c"
- "opt"
build_targets:
- "//src:bazel.exe"
- "//src:bazel_nojdk.exe"
| ---
platforms:
centos7:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1604:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1804:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu2004:
build_targets:
- "//src:bazel"
build_flags:
- "-c"
- "opt"
macos:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
windows:
build_flags:
- "--copt=-w"
- "--host_copt=-w"
- "-c"
- "opt"
build_targets:
- "//src:bazel.exe"
- "//src:bazel_nojdk.exe"
| Add Ubuntu 20.04 platform, but do not test it in CI yet | Add Ubuntu 20.04 platform, but do not test it in CI yet
This seems like it might be a prerequisite for adding a ubuntu 20.04 platform to bazelci, based on this CI failure:
https://github.com/bazelbuild/continuous-integration/pull/988
Closes #11630.
PiperOrigin-RevId: 333290900
| YAML | apache-2.0 | bazelbuild/bazel,cushon/bazel,cushon/bazel,meteorcloudy/bazel,ButterflyNetwork/bazel,twitter-forks/bazel,katre/bazel,perezd/bazel,bazelbuild/bazel,ButterflyNetwork/bazel,davidzchen/bazel,perezd/bazel,twitter-forks/bazel,katre/bazel,perezd/bazel,safarmer/bazel,safarmer/bazel,perezd/bazel,perezd/bazel,bazelbuild/bazel,bazelbuild/bazel,davidzchen/bazel,twitter-forks/bazel,ButterflyNetwork/bazel,safarmer/bazel,ButterflyNetwork/bazel,meteorcloudy/bazel,davidzchen/bazel,safarmer/bazel,katre/bazel,bazelbuild/bazel,cushon/bazel,katre/bazel,davidzchen/bazel,cushon/bazel,meteorcloudy/bazel,safarmer/bazel,davidzchen/bazel,meteorcloudy/bazel,perezd/bazel,davidzchen/bazel,davidzchen/bazel,meteorcloudy/bazel,bazelbuild/bazel,twitter-forks/bazel,twitter-forks/bazel,meteorcloudy/bazel,meteorcloudy/bazel,cushon/bazel,katre/bazel,ButterflyNetwork/bazel,twitter-forks/bazel,ButterflyNetwork/bazel,cushon/bazel,safarmer/bazel,katre/bazel,perezd/bazel,twitter-forks/bazel | yaml | ## Code Before:
---
platforms:
centos7:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1604:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1804:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
macos:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
windows:
build_flags:
- "--copt=-w"
- "--host_copt=-w"
- "-c"
- "opt"
build_targets:
- "//src:bazel.exe"
- "//src:bazel_nojdk.exe"
## Instruction:
Add Ubuntu 20.04 platform, but do not test it in CI yet
This seems like it might be a prerequisite for adding a ubuntu 20.04 platform to bazelci, based on this CI failure:
https://github.com/bazelbuild/continuous-integration/pull/988
Closes #11630.
PiperOrigin-RevId: 333290900
## Code After:
---
platforms:
centos7:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1604:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu1804:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
ubuntu2004:
build_targets:
- "//src:bazel"
build_flags:
- "-c"
- "opt"
macos:
build_targets:
- "//src:bazel"
- "//src:bazel_nojdk"
build_flags:
- "-c"
- "opt"
windows:
build_flags:
- "--copt=-w"
- "--host_copt=-w"
- "-c"
- "opt"
build_targets:
- "//src:bazel.exe"
- "//src:bazel_nojdk.exe"
|
9004da9bd159e66e4e6a58e5379502e24fffd80e | app/views/settings/_services.haml | app/views/settings/_services.haml | .card
.card-body
= t(".services", count: services.count)
- APP_CONFIG["sharing"].each do |service, service_options|
- if service_options["enabled"] && services.none? { |x| x.provider == service.to_s }
%p= button_to t(".connect", service: service.capitalize), "/auth/#{service}", method: :post, class: "btn btn-info"
- if services.count.positive?
%ul.list-group
- services.each do |service|
%li.list-group-item
%i{ class: "fa fa-#{service.provider}" }
%strong= service.provider.capitalize
(#{service.nickname})
= button_to t(".disconnect"),
service_path(service),
data: { confirm: t(".confirm", service: service.provider.capitalize) },
method: :delete,
class: "btn btn-link text-danger",
form: { class: "d-inline" }
.col-md-6.mt-2
= bootstrap_form_for(service, as: "service", url: update_service_path(service)) do |f|
= f.text_field :post_tag, label_as_placeholder: true,
append: f.submit(t("voc.update"), class: "btn btn-primary"), maxlength: 20, pattern: "^[^@]*$"
| .card
.card-body
= t(".services", count: services.count)
- APP_CONFIG["sharing"].each do |service, service_options|
- if service_options["enabled"] && services.none? { |x| x.provider == service.to_s }
%p= button_to t(".connect", service: service.capitalize), "/auth/#{service}", method: :post, class: "btn btn-info",
form: { data: { turbo: false } }
- if services.count.positive?
%ul.list-group
- services.each do |service|
%li.list-group-item
%i{ class: "fa fa-#{service.provider}" }
%strong= service.provider.capitalize
(#{service.nickname})
= button_to t(".disconnect"),
service_path(service),
data: { confirm: t(".confirm", service: service.provider.capitalize) },
method: :delete,
class: "btn btn-link text-danger",
form: { class: "d-inline", data: { turbo: false } }
.col-md-6.mt-2
= bootstrap_form_for(service, as: "service", url: update_service_path(service), data: { turbo: false }) do |f|
= f.text_field :post_tag, label_as_placeholder: true,
append: f.submit(t("voc.update"), class: "btn btn-primary"), maxlength: 20, pattern: "^[^@]*$"
| Disable Turbo on Service Settings | Disable Turbo on Service Settings
| Haml | agpl-3.0 | Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring | haml | ## Code Before:
.card
.card-body
= t(".services", count: services.count)
- APP_CONFIG["sharing"].each do |service, service_options|
- if service_options["enabled"] && services.none? { |x| x.provider == service.to_s }
%p= button_to t(".connect", service: service.capitalize), "/auth/#{service}", method: :post, class: "btn btn-info"
- if services.count.positive?
%ul.list-group
- services.each do |service|
%li.list-group-item
%i{ class: "fa fa-#{service.provider}" }
%strong= service.provider.capitalize
(#{service.nickname})
= button_to t(".disconnect"),
service_path(service),
data: { confirm: t(".confirm", service: service.provider.capitalize) },
method: :delete,
class: "btn btn-link text-danger",
form: { class: "d-inline" }
.col-md-6.mt-2
= bootstrap_form_for(service, as: "service", url: update_service_path(service)) do |f|
= f.text_field :post_tag, label_as_placeholder: true,
append: f.submit(t("voc.update"), class: "btn btn-primary"), maxlength: 20, pattern: "^[^@]*$"
## Instruction:
Disable Turbo on Service Settings
## Code After:
.card
.card-body
= t(".services", count: services.count)
- APP_CONFIG["sharing"].each do |service, service_options|
- if service_options["enabled"] && services.none? { |x| x.provider == service.to_s }
%p= button_to t(".connect", service: service.capitalize), "/auth/#{service}", method: :post, class: "btn btn-info",
form: { data: { turbo: false } }
- if services.count.positive?
%ul.list-group
- services.each do |service|
%li.list-group-item
%i{ class: "fa fa-#{service.provider}" }
%strong= service.provider.capitalize
(#{service.nickname})
= button_to t(".disconnect"),
service_path(service),
data: { confirm: t(".confirm", service: service.provider.capitalize) },
method: :delete,
class: "btn btn-link text-danger",
form: { class: "d-inline", data: { turbo: false } }
.col-md-6.mt-2
= bootstrap_form_for(service, as: "service", url: update_service_path(service), data: { turbo: false }) do |f|
= f.text_field :post_tag, label_as_placeholder: true,
append: f.submit(t("voc.update"), class: "btn btn-primary"), maxlength: 20, pattern: "^[^@]*$"
|
82c8cc9779abf952d3558cdc06692a5cb78340dc | survey_creation/2017/zaf/listAnswers/funding.csv | survey_creation/2017/zaf/listAnswers/funding.csv | I volunteer my time
Donation button
Crowdfunding (one-time)
Crowdfunding (recurring)
Books & merchandise
Advertising & sponsorships
Industry support
Consulting & services
Grants
SaaS
Membership
Dual license
Open core
Foundations & consortiums
Venture capital
Trademark licensing & franchising
| I volunteer my time
Donation button
Crowdfunding (one-time)
Crowdfunding (recurring)
Books & merchandise
Advertising & sponsorships
Industry support
Consulting & services
Grants
SaaS
Membership
Dual license
Open core
Foundations & consortiums
Venture capital
Trademark licensing & franchising
Not applicable
| Add NA based on fund4 change in question | Add NA based on fund4 change in question | CSV | bsd-3-clause | softwaresaved/international-survey | csv | ## Code Before:
I volunteer my time
Donation button
Crowdfunding (one-time)
Crowdfunding (recurring)
Books & merchandise
Advertising & sponsorships
Industry support
Consulting & services
Grants
SaaS
Membership
Dual license
Open core
Foundations & consortiums
Venture capital
Trademark licensing & franchising
## Instruction:
Add NA based on fund4 change in question
## Code After:
I volunteer my time
Donation button
Crowdfunding (one-time)
Crowdfunding (recurring)
Books & merchandise
Advertising & sponsorships
Industry support
Consulting & services
Grants
SaaS
Membership
Dual license
Open core
Foundations & consortiums
Venture capital
Trademark licensing & franchising
Not applicable
|
b84af83df8ebc9ac5ce05cf866a159ea1ee758a5 | .github/workflows/build.yml | .github/workflows/build.yml | name: Node.js Builds
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- node-version: 12.x
- node-version: 14.x
status: "LTS"
- node-version: 16.x
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Build
run: |
npm install
npm run build
- name: Package
run: npm pack
- name: Test
run: npm run nyc-ci
- name: Login to DockerHub
uses: docker/login-action@v1
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push to DockerHub
id: docker_build
uses: docker/build-push-action@v2
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
context: .
push: true
tags: rcjsuen/docker-langserver:latest
- name: Coveralls
uses: coverallsapp/github-action@master
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
| name: Node.js Builds
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- node-version: 12.x
- node-version: 14.x
- node-version: 16.x
status: "LTS"
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Build
run: |
npm install
npm run build
- name: Package
run: npm pack
- name: Test
run: npm run nyc-ci
- name: Login to DockerHub
uses: docker/login-action@v1
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push to DockerHub
id: docker_build
uses: docker/build-push-action@v2
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
context: .
push: true
tags: rcjsuen/docker-langserver:latest
- name: Coveralls
uses: coverallsapp/github-action@master
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
| Change LTS to Node.js 16.x | Change LTS to Node.js 16.x
Signed-off-by: Remy Suen <553f7e7fc51e9ff47ae89d5a0ebd06651241b998@gmail.com>
| YAML | mit | rcjsuen/dockerfile-language-server-nodejs,rcjsuen/dockerfile-language-server-nodejs | yaml | ## Code Before:
name: Node.js Builds
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- node-version: 12.x
- node-version: 14.x
status: "LTS"
- node-version: 16.x
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Build
run: |
npm install
npm run build
- name: Package
run: npm pack
- name: Test
run: npm run nyc-ci
- name: Login to DockerHub
uses: docker/login-action@v1
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push to DockerHub
id: docker_build
uses: docker/build-push-action@v2
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
context: .
push: true
tags: rcjsuen/docker-langserver:latest
- name: Coveralls
uses: coverallsapp/github-action@master
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
## Instruction:
Change LTS to Node.js 16.x
Signed-off-by: Remy Suen <553f7e7fc51e9ff47ae89d5a0ebd06651241b998@gmail.com>
## Code After:
name: Node.js Builds
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- node-version: 12.x
- node-version: 14.x
- node-version: 16.x
status: "LTS"
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Build
run: |
npm install
npm run build
- name: Package
run: npm pack
- name: Test
run: npm run nyc-ci
- name: Login to DockerHub
uses: docker/login-action@v1
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push to DockerHub
id: docker_build
uses: docker/build-push-action@v2
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
context: .
push: true
tags: rcjsuen/docker-langserver:latest
- name: Coveralls
uses: coverallsapp/github-action@master
if: ${{ matrix.status == 'LTS' && github.ref == 'refs/heads/master' }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
|
d4c77fddf2db051e43e512a08f6f9438eaad8957 | pillars/profile/common/system_maven_artifacts/compare_order.sh | pillars/profile/common/system_maven_artifacts/compare_order.sh | grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls > existing.order.txt
grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls | sort > required.order.txt
echo "Compare order of entries in the files using one of the command below:" 1>&2
echo " meld existing.order.txt required.order.txt" 1>&2
echo " diff existing.order.txt required.order.txt" 1>&2
|
set -e
set -u
# This is a helper script to generate required and existing order
# of items inside `artifact_descriptors.sls` file.
# Note that duplicates also cause error code in addition to unordered ones.
# The search is done for strings (keys) containing GROUP_ID:ARTIFACT_ID.
grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls > existing.order.txt
grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls | sort -u > required.order.txt
set -e
diff existing.order.txt required.order.txt 1>&2
RET_VAL="$?"
set +e
if [ "${RET_VAL}" != "0" ]
then
echo "WARNING: The list of artifacts is not ordered or has duplicates." 1>&2
echo " The order is required to simplify merging of concurrent changes." 1>&2
echo "Compare order of entries in the files using one of the command below:" 1>&2
echo " meld existing.order.txt required.order.txt" 1>&2
echo " diff existing.order.txt required.order.txt" 1>&2
exit "${RET_VAL}"
else
echo "INFO: Files existing.order.txt required.order.txt are the same." 1>&2
fi
| Add exit code if artifacts not ordered or dup-ed | Add exit code if artifacts not ordered or dup-ed
| Shell | apache-2.0 | uvsmtid/common-salt-states,uvsmtid/common-salt-states,uvsmtid/common-salt-states,uvsmtid/common-salt-states | shell | ## Code Before:
grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls > existing.order.txt
grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls | sort > required.order.txt
echo "Compare order of entries in the files using one of the command below:" 1>&2
echo " meld existing.order.txt required.order.txt" 1>&2
echo " diff existing.order.txt required.order.txt" 1>&2
## Instruction:
Add exit code if artifacts not ordered or dup-ed
## Code After:
set -e
set -u
# This is a helper script to generate required and existing order
# of items inside `artifact_descriptors.sls` file.
# Note that duplicates also cause error code in addition to unordered ones.
# The search is done for strings (keys) containing GROUP_ID:ARTIFACT_ID.
grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls > existing.order.txt
grep -r '^[^:][^:]*:[^:][^:]*:[[:space:]]*$' artifact_descriptors.sls | sort -u > required.order.txt
set -e
diff existing.order.txt required.order.txt 1>&2
RET_VAL="$?"
set +e
if [ "${RET_VAL}" != "0" ]
then
echo "WARNING: The list of artifacts is not ordered or has duplicates." 1>&2
echo " The order is required to simplify merging of concurrent changes." 1>&2
echo "Compare order of entries in the files using one of the command below:" 1>&2
echo " meld existing.order.txt required.order.txt" 1>&2
echo " diff existing.order.txt required.order.txt" 1>&2
exit "${RET_VAL}"
else
echo "INFO: Files existing.order.txt required.order.txt are the same." 1>&2
fi
|
73c26ecb3c13040bf7df2cf65a0fae3895ffe851 | README.md | README.md | Demo project: AngularJS component to manage tasks between multiple users
[![Build Status](https://api.travis-ci.org/stophi-dev/NgTeamTask.svg?branch=master)](https://travis-ci.org/stophi-dev/NgTeamTask)
## How to run this project
You need git and NodeJS installed on your computer.
###1. Clone the git repository
```bash
git clone https://github.com/stophi-dev/NgTeamTask.git
```
###2. Install the project dependencies
```bash
cd NgTeamTask
npm install
```
###3. Start project (local web server and browser)
```bash
npm start
```
This project works out of the box with the NetBeans IDE 8.1.
| Demo project: AngularJS component to manage tasks between multiple users<br />
[![Build Status](https://api.travis-ci.org/stophi-dev/NgTeamTask.svg?branch=master)](https://travis-ci.org/stophi-dev/NgTeamTask)
(Currently only checks if compilation of SASS file is sucessful)
## How to run this project
You need git and NodeJS installed on your computer.
###1. Clone the git repository
```bash
git clone https://github.com/stophi-dev/NgTeamTask.git
```
###2. Install the project dependencies
```bash
cd NgTeamTask
npm install
```
###3. Start project (local web server and browser)
```bash
npm start
```
This project works out of the box with the NetBeans IDE 8.1.
| Add description for travis build | Add description for travis build | Markdown | mit | stophi-dev/NgTeamTask,stophi-dev/NgTeamTask | markdown | ## Code Before:
Demo project: AngularJS component to manage tasks between multiple users
[![Build Status](https://api.travis-ci.org/stophi-dev/NgTeamTask.svg?branch=master)](https://travis-ci.org/stophi-dev/NgTeamTask)
## How to run this project
You need git and NodeJS installed on your computer.
###1. Clone the git repository
```bash
git clone https://github.com/stophi-dev/NgTeamTask.git
```
###2. Install the project dependencies
```bash
cd NgTeamTask
npm install
```
###3. Start project (local web server and browser)
```bash
npm start
```
This project works out of the box with the NetBeans IDE 8.1.
## Instruction:
Add description for travis build
## Code After:
Demo project: AngularJS component to manage tasks between multiple users<br />
[![Build Status](https://api.travis-ci.org/stophi-dev/NgTeamTask.svg?branch=master)](https://travis-ci.org/stophi-dev/NgTeamTask)
(Currently only checks if compilation of SASS file is sucessful)
## How to run this project
You need git and NodeJS installed on your computer.
###1. Clone the git repository
```bash
git clone https://github.com/stophi-dev/NgTeamTask.git
```
###2. Install the project dependencies
```bash
cd NgTeamTask
npm install
```
###3. Start project (local web server and browser)
```bash
npm start
```
This project works out of the box with the NetBeans IDE 8.1.
|
321f5baef6abbe4a43acc55e3ae8c81367e0cd9a | README.md | README.md | SDL2 Pong
==========
Simple implementation of pong using SDL2.0
This is a single player game with the second paddle being controlled by an *extremely* simple AI.
![Pong on Kubuntu](img/sdl_pong2.png)
Controls
--------
* Up - move up
* Down - move down
* Escape - Exit
Requirements
------------
You require the SDL2.0 development libraries along with the following extensions:
* SDL_ttf
* SDL_image
Building
--------
Simply Navigate to the src directory and type `make`
Executing
---------
Run `pong.exe`
Notes
-----
This was tested on a Linux machine (64bit) but should also work and compile on Windows and Mac OSX given the right development tools.
| SDL2 Pong
==========
Simple implementation of pong using SDL2.0
This is a single player game with the second paddle being controlled by an *extremely* simple AI.
![Pong on Kubuntu](img/sdl_pong2.png)
Controls
--------
* Up - move up
* Down - move down
* Escape - Exit
Controller Support
------------------
The game has very basic controller support. You can use the up and down buttons to move your paddle. I also introduced some basic haptic feedback when the ball hits a paddle or one of the players score a point.
Requirements
------------
You require the SDL2.0 development libraries along with the following extensions:
* SDL_ttf
* SDL_image
Building
--------
Simply Navigate to the src directory and type `make`
Executing
---------
Run `pong.exe`
Notes
-----
This was tested on a Linux machine (64bit) but should also work and compile on Windows and Mac OSX given the right development tools.
| Add note about controller support | Add note about controller support
Haptic feedback also included | Markdown | mit | MichaelAquilina/SDL2-Pong | markdown | ## Code Before:
SDL2 Pong
==========
Simple implementation of pong using SDL2.0
This is a single player game with the second paddle being controlled by an *extremely* simple AI.
![Pong on Kubuntu](img/sdl_pong2.png)
Controls
--------
* Up - move up
* Down - move down
* Escape - Exit
Requirements
------------
You require the SDL2.0 development libraries along with the following extensions:
* SDL_ttf
* SDL_image
Building
--------
Simply Navigate to the src directory and type `make`
Executing
---------
Run `pong.exe`
Notes
-----
This was tested on a Linux machine (64bit) but should also work and compile on Windows and Mac OSX given the right development tools.
## Instruction:
Add note about controller support
Haptic feedback also included
## Code After:
SDL2 Pong
==========
Simple implementation of pong using SDL2.0
This is a single player game with the second paddle being controlled by an *extremely* simple AI.
![Pong on Kubuntu](img/sdl_pong2.png)
Controls
--------
* Up - move up
* Down - move down
* Escape - Exit
Controller Support
------------------
The game has very basic controller support. You can use the up and down buttons to move your paddle. I also introduced some basic haptic feedback when the ball hits a paddle or one of the players score a point.
Requirements
------------
You require the SDL2.0 development libraries along with the following extensions:
* SDL_ttf
* SDL_image
Building
--------
Simply Navigate to the src directory and type `make`
Executing
---------
Run `pong.exe`
Notes
-----
This was tested on a Linux machine (64bit) but should also work and compile on Windows and Mac OSX given the right development tools.
|
387c77585909e73773d1c97a782667f951cda67d | .travis.yml | .travis.yml | language: ruby
rvm:
- 1.9.3
- 2.0.0
- 2.1.10
- 2.2.5
- 2.3.1
matrix:
allow_failures:
- rvm: 1.9.3
- rvm: 2.0.0
before_install:
# this is a fix to get rng-tools to work in travis-ci
- sudo apt-get update -qq
- sudo apt-get install --yes rng-tools
- sudo rm -f /dev/random
- sudo mknod -m 0666 /dev/random c 1 9
- echo HRNGDEVICE=/dev/urandom | sudo tee /etc/default/rng-tools
- sudo /etc/init.d/rng-tools restart
script: travis_wait bundle exec rake TESTOPTS="-v"
after_failure:
"find tmp -name compile.log -exec cat {} \\;"
| language: ruby
rvm:
- 1.9.3
- 2.0.0
- 2.1.10
- 2.2.9
- 2.3.6
- 2.4.3
- 2.5.0
matrix:
allow_failures:
- rvm: 1.9.3
- rvm: 2.0.0
before_install:
# this is a fix to get rng-tools to work in travis-ci
- sudo apt-get update -qq
- sudo apt-get install --yes rng-tools
- sudo rm -f /dev/random
- sudo mknod -m 0666 /dev/random c 1 9
- echo HRNGDEVICE=/dev/urandom | sudo tee /etc/default/rng-tools
- sudo /etc/init.d/rng-tools restart
script: travis_wait bundle exec rake TESTOPTS="-v"
after_failure:
"find tmp -name compile.log -exec cat {} \\;"
| Test against Ruby 2.4 and .5 | [CI] Test against Ruby 2.4 and .5 | YAML | lgpl-2.1 | ueno/ruby-gpgme,ueno/ruby-gpgme,ueno/ruby-gpgme | yaml | ## Code Before:
language: ruby
rvm:
- 1.9.3
- 2.0.0
- 2.1.10
- 2.2.5
- 2.3.1
matrix:
allow_failures:
- rvm: 1.9.3
- rvm: 2.0.0
before_install:
# this is a fix to get rng-tools to work in travis-ci
- sudo apt-get update -qq
- sudo apt-get install --yes rng-tools
- sudo rm -f /dev/random
- sudo mknod -m 0666 /dev/random c 1 9
- echo HRNGDEVICE=/dev/urandom | sudo tee /etc/default/rng-tools
- sudo /etc/init.d/rng-tools restart
script: travis_wait bundle exec rake TESTOPTS="-v"
after_failure:
"find tmp -name compile.log -exec cat {} \\;"
## Instruction:
[CI] Test against Ruby 2.4 and .5
## Code After:
language: ruby
rvm:
- 1.9.3
- 2.0.0
- 2.1.10
- 2.2.9
- 2.3.6
- 2.4.3
- 2.5.0
matrix:
allow_failures:
- rvm: 1.9.3
- rvm: 2.0.0
before_install:
# this is a fix to get rng-tools to work in travis-ci
- sudo apt-get update -qq
- sudo apt-get install --yes rng-tools
- sudo rm -f /dev/random
- sudo mknod -m 0666 /dev/random c 1 9
- echo HRNGDEVICE=/dev/urandom | sudo tee /etc/default/rng-tools
- sudo /etc/init.d/rng-tools restart
script: travis_wait bundle exec rake TESTOPTS="-v"
after_failure:
"find tmp -name compile.log -exec cat {} \\;"
|
36953e58cc2825de5315341f818b65fe22ba0b28 | install/DoctrineMigrations/Version20110711161043.php | install/DoctrineMigrations/Version20110711161043.php | <?php
namespace DoctrineMigrations;
/*
update cc_files table to include to "directory" column as well as add foreign key relation to
cc_music_dirs table.
*/
use Doctrine\DBAL\Migrations\AbstractMigration,
Doctrine\DBAL\Schema\Schema;
class Version20110711161043 extends AbstractMigration
{
public function up(Schema $schema)
{
//CREATE the default value of "/srv/airtime/stor", this can be updated later in the upgrade script.
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('stor', '/srv/airtime/stor');");
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('upgrade', '');");
}
public function postUp(Schema $schema){
$cc_music_dirs = $schema->getTable('cc_music_dirs');
//start cc_files modifications
$cc_files = $schema->getTable('cc_files');
$cc_files->addColumn('directory', 'integer', array('default'=> 2));
$cc_files->addNamedForeignKeyConstraint('cc_music_dirs_folder_fkey', $cc_music_dirs, array('directory'), array('id'), array('onDelete' => 'CASCADE'));
//end cc_files modifications
}
public function down(Schema $schema)
{
}
}
| <?php
namespace DoctrineMigrations;
/*
update cc_files table to include to "directory" column as well as add foreign key relation to
cc_music_dirs table.
*/
use Doctrine\DBAL\Migrations\AbstractMigration,
Doctrine\DBAL\Schema\Schema;
class Version20110711161043 extends AbstractMigration
{
public function up(Schema $schema)
{
//CREATE the default value of "/srv/airtime/stor", this can be updated later in the upgrade script.
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('stor', '/srv/airtime/stor');");
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('upgrade', '');");
$cc_music_dirs = $schema->getTable('cc_music_dirs');
//start cc_files modifications
$cc_files = $schema->getTable('cc_files');
$cc_files->addColumn('directory', 'integer', array('default'=> 2));
$cc_files->addNamedForeignKeyConstraint('cc_music_dirs_folder_fkey', $cc_music_dirs, array('directory'), array('id'), array('onDelete' => 'CASCADE'));
//end cc_files modifications
}
public function down(Schema $schema)
{
}
}
| Upgrade script for converting stor directory to new format | CC-2279: Upgrade script for converting stor directory to new format
-almost there...
| PHP | agpl-3.0 | thnkloud9/Airtime,sourcefabric/Airtime,comiconomenclaturist/libretime,sourcefabric/airtime,thnkloud9/Airtime,LibreTime/libretime,ReganDryke/airtime,thnkloud9/Airtime,LibreTime/libretime,Ryex/airtime,radiorabe/airtime,Ryex/airtime,radiorabe/airtime,radiorabe/airtime,sourcefabric/airtime,justvanbloom/airtime,Lapotor/libretime,justvanbloom/airtime,thnkloud9/Airtime,sourcefabric/Airtime,Lapotor/libretime,sourcefabric/airtime,ReganDryke/airtime,comiconomenclaturist/libretime,Lapotor/libretime,radiorabe/airtime,sourcefabric/airtime,LibreTime/libretime,ReganDryke/airtime,Lapotor/libretime,sourcefabric/airtime,Lapotor/libretime,thnkloud9/Airtime,justvanbloom/airtime,thnkloud9/Airtime,comiconomenclaturist/libretime,Ryex/airtime,LibreTime/libretime,justvanbloom/airtime,Ryex/airtime,Ryex/airtime,sourcefabric/Airtime,sourcefabric/Airtime,comiconomenclaturist/libretime,radiorabe/airtime,radiorabe/airtime,sourcefabric/Airtime,comiconomenclaturist/libretime,justvanbloom/airtime,Lapotor/libretime,ReganDryke/airtime,sourcefabric/airtime,justvanbloom/airtime,Ryex/airtime,ReganDryke/airtime,ReganDryke/airtime,comiconomenclaturist/libretime,comiconomenclaturist/libretime,thnkloud9/Airtime,LibreTime/libretime,ReganDryke/airtime,sourcefabric/airtime,justvanbloom/airtime,sourcefabric/Airtime,Ryex/airtime,sourcefabric/Airtime,LibreTime/libretime,radiorabe/airtime | php | ## Code Before:
<?php
namespace DoctrineMigrations;
/*
update cc_files table to include to "directory" column as well as add foreign key relation to
cc_music_dirs table.
*/
use Doctrine\DBAL\Migrations\AbstractMigration,
Doctrine\DBAL\Schema\Schema;
class Version20110711161043 extends AbstractMigration
{
public function up(Schema $schema)
{
//CREATE the default value of "/srv/airtime/stor", this can be updated later in the upgrade script.
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('stor', '/srv/airtime/stor');");
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('upgrade', '');");
}
public function postUp(Schema $schema){
$cc_music_dirs = $schema->getTable('cc_music_dirs');
//start cc_files modifications
$cc_files = $schema->getTable('cc_files');
$cc_files->addColumn('directory', 'integer', array('default'=> 2));
$cc_files->addNamedForeignKeyConstraint('cc_music_dirs_folder_fkey', $cc_music_dirs, array('directory'), array('id'), array('onDelete' => 'CASCADE'));
//end cc_files modifications
}
public function down(Schema $schema)
{
}
}
## Instruction:
CC-2279: Upgrade script for converting stor directory to new format
-almost there...
## Code After:
<?php
namespace DoctrineMigrations;
/*
update cc_files table to include to "directory" column as well as add foreign key relation to
cc_music_dirs table.
*/
use Doctrine\DBAL\Migrations\AbstractMigration,
Doctrine\DBAL\Schema\Schema;
class Version20110711161043 extends AbstractMigration
{
public function up(Schema $schema)
{
//CREATE the default value of "/srv/airtime/stor", this can be updated later in the upgrade script.
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('stor', '/srv/airtime/stor');");
$this->_addSql("INSERT INTO cc_music_dirs (type, directory) VALUES ('upgrade', '');");
$cc_music_dirs = $schema->getTable('cc_music_dirs');
//start cc_files modifications
$cc_files = $schema->getTable('cc_files');
$cc_files->addColumn('directory', 'integer', array('default'=> 2));
$cc_files->addNamedForeignKeyConstraint('cc_music_dirs_folder_fkey', $cc_music_dirs, array('directory'), array('id'), array('onDelete' => 'CASCADE'));
//end cc_files modifications
}
public function down(Schema $schema)
{
}
}
|
d3291512db02304c0948992436817d36f86046fd | stdlib/public/SDK/simd/CMakeLists.txt | stdlib/public/SDK/simd/CMakeLists.txt | add_swift_library(swiftsimd SHARED IS_STDLIB
simd.swift.gyb
SWIFT_COMPILE_FLAGS -Xfrontend -sil-serialize-all
SWIFT_MODULE_DEPENDS Darwin
INSTALL_IN_COMPONENT stdlib)
| add_swift_library(swiftsimd IS_SDK_OVERLAY
simd.swift.gyb
SWIFT_COMPILE_FLAGS -Xfrontend -sil-serialize-all
SWIFT_MODULE_DEPENDS Darwin)
| Make the 'simd' module build like the rest of the overlays. | Make the 'simd' module build like the rest of the overlays.
At one point we were considering it to be a replacement rather than an
overlay, but that's not where we are today. We can revisit that later.
Necessary for next commit.
Swift SVN r29438
| Text | apache-2.0 | airspeedswift/swift,djwbrown/swift,apple/swift,hughbe/swift,hughbe/swift,xedin/swift,IngmarStein/swift,calebd/swift,tinysun212/swift-windows,JaSpa/swift,tardieu/swift,glessard/swift,emilstahl/swift,kentya6/swift,aschwaighofer/swift,arvedviehweger/swift,gregomni/swift,tjw/swift,return/swift,bitjammer/swift,jmgc/swift,arvedviehweger/swift,modocache/swift,gottesmm/swift,SwiftAndroid/swift,gmilos/swift,devincoughlin/swift,austinzheng/swift,russbishop/swift,gribozavr/swift,natecook1000/swift,atrick/swift,kusl/swift,natecook1000/swift,shajrawi/swift,alblue/swift,modocache/swift,jtbandes/swift,apple/swift,manavgabhawala/swift,JaSpa/swift,jopamer/swift,tinysun212/swift-windows,hooman/swift,jtbandes/swift,return/swift,aschwaighofer/swift,harlanhaskins/swift,KrishMunot/swift,codestergit/swift,khizkhiz/swift,jtbandes/swift,natecook1000/swift,xedin/swift,benlangmuir/swift,milseman/swift,felix91gr/swift,frootloops/swift,bitjammer/swift,karwa/swift,swiftix/swift,shajrawi/swift,shajrawi/swift,jopamer/swift,milseman/swift,atrick/swift,sschiau/swift,jckarter/swift,gmilos/swift,aschwaighofer/swift,swiftix/swift.old,mightydeveloper/swift,ben-ng/swift,JaSpa/swift,xwu/swift,gottesmm/swift,gottesmm/swift,therealbnut/swift,xwu/swift,djwbrown/swift,alblue/swift,xwu/swift,OscarSwanros/swift,cbrentharris/swift,SwiftAndroid/swift,OscarSwanros/swift,kusl/swift,gribozavr/swift,zisko/swift,amraboelela/swift,austinzheng/swift,stephentyrone/swift,milseman/swift,JaSpa/swift,benlangmuir/swift,emilstahl/swift,mightydeveloper/swift,KrishMunot/swift,uasys/swift,kperryua/swift,arvedviehweger/swift,tardieu/swift,Ivacker/swift,ken0nek/swift,bitjammer/swift,airspeedswift/swift,airspeedswift/swift,zisko/swift,slavapestov/swift,xwu/swift,KrishMunot/swift,frootloops/swift,sdulal/swift,benlangmuir/swift,codestergit/swift,lorentey/swift,stephentyrone/swift,djwbrown/swift,rudkx/swift,calebd/swift,parkera/swift,MukeshKumarS/Swift,swiftix/swift,alblue/swift,bitjammer/swift,tjw/swift,KrishMunot/swift,airspeedswift/swift,frootloops/swift,kperryua/swift,CodaFi/swift,russbishop/swift,zisko/swift,sdulal/swift,cbrentharris/swift,practicalswift/swift,dduan/swift,nathawes/swift,atrick/swift,calebd/swift,therealbnut/swift,johnno1962d/swift,gregomni/swift,devincoughlin/swift,practicalswift/swift,allevato/swift,alblue/swift,dduan/swift,JGiola/swift,jckarter/swift,modocache/swift,gottesmm/swift,shahmishal/swift,karwa/swift,benlangmuir/swift,cbrentharris/swift,kusl/swift,adrfer/swift,djwbrown/swift,uasys/swift,xwu/swift,nathawes/swift,jmgc/swift,MukeshKumarS/Swift,ken0nek/swift,jmgc/swift,gmilos/swift,kentya6/swift,xwu/swift,jopamer/swift,dduan/swift,amraboelela/swift,aschwaighofer/swift,adrfer/swift,devincoughlin/swift,russbishop/swift,natecook1000/swift,MukeshKumarS/Swift,shahmishal/swift,JGiola/swift,lorentey/swift,jmgc/swift,alblue/swift,hughbe/swift,atrick/swift,manavgabhawala/swift,Jnosh/swift,swiftix/swift.old,bitjammer/swift,nathawes/swift,gmilos/swift,therealbnut/swift,russbishop/swift,milseman/swift,modocache/swift,xedin/swift,sdulal/swift,gmilos/swift,xedin/swift,return/swift,Ivacker/swift,kstaring/swift,sdulal/swift,adrfer/swift,Jnosh/swift,JGiola/swift,danielmartin/swift,codestergit/swift,johnno1962d/swift,therealbnut/swift,johnno1962d/swift,ken0nek/swift,codestergit/swift,amraboelela/swift,CodaFi/swift,glessard/swift,felix91gr/swift,calebd/swift,practicalswift/swift,gregomni/swift,emilstahl/swift,adrfer/swift,roambotics/swift,kentya6/swift,tkremenek/swift,tkremenek/swift,jckarter/swift,return/swift,roambotics/swift,shajrawi/swift,arvedviehweger/swift,sdulal/swift,glessard/swift,sdulal/swift,slavapestov/swift,danielmartin/swift,codestergit/swift,glessard/swift,zisko/swift,parkera/swift,aschwaighofer/swift,manavgabhawala/swift,deyton/swift,tjw/swift,tjw/swift,kusl/swift,nathawes/swift,MukeshKumarS/Swift,milseman/swift,return/swift,tardieu/swift,shahmishal/swift,tardieu/swift,LeoShimonaka/swift,airspeedswift/swift,austinzheng/swift,johnno1962d/swift,felix91gr/swift,IngmarStein/swift,parkera/swift,tardieu/swift,kusl/swift,stephentyrone/swift,huonw/swift,devincoughlin/swift,amraboelela/swift,danielmartin/swift,jopamer/swift,OscarSwanros/swift,MukeshKumarS/Swift,felix91gr/swift,codestergit/swift,stephentyrone/swift,practicalswift/swift,mightydeveloper/swift,jckarter/swift,sschiau/swift,kentya6/swift,LeoShimonaka/swift,dduan/swift,djwbrown/swift,slavapestov/swift,gribozavr/swift,roambotics/swift,SwiftAndroid/swift,sdulal/swift,amraboelela/swift,kstaring/swift,therealbnut/swift,slavapestov/swift,uasys/swift,slavapestov/swift,airspeedswift/swift,milseman/swift,IngmarStein/swift,shajrawi/swift,dduan/swift,allevato/swift,tinysun212/swift-windows,karwa/swift,sschiau/swift,jckarter/swift,kstaring/swift,adrfer/swift,ken0nek/swift,mightydeveloper/swift,apple/swift,cbrentharris/swift,rudkx/swift,ahoppen/swift,karwa/swift,austinzheng/swift,sschiau/swift,SwiftAndroid/swift,gregomni/swift,Jnosh/swift,devincoughlin/swift,parkera/swift,xedin/swift,gottesmm/swift,SwiftAndroid/swift,jopamer/swift,codestergit/swift,ben-ng/swift,ben-ng/swift,lorentey/swift,IngmarStein/swift,kperryua/swift,bitjammer/swift,gribozavr/swift,xedin/swift,johnno1962d/swift,shahmishal/swift,ken0nek/swift,therealbnut/swift,mightydeveloper/swift,natecook1000/swift,gottesmm/swift,russbishop/swift,IngmarStein/swift,tinysun212/swift-windows,allevato/swift,OscarSwanros/swift,harlanhaskins/swift,benlangmuir/swift,shajrawi/swift,swiftix/swift.old,MukeshKumarS/Swift,kentya6/swift,aschwaighofer/swift,swiftix/swift.old,jtbandes/swift,huonw/swift,practicalswift/swift,huonw/swift,harlanhaskins/swift,deyton/swift,sschiau/swift,shajrawi/swift,rudkx/swift,tjw/swift,lorentey/swift,khizkhiz/swift,cbrentharris/swift,ben-ng/swift,SwiftAndroid/swift,emilstahl/swift,hooman/swift,practicalswift/swift,swiftix/swift,SwiftAndroid/swift,stephentyrone/swift,emilstahl/swift,gregomni/swift,LeoShimonaka/swift,practicalswift/swift,stephentyrone/swift,uasys/swift,jtbandes/swift,khizkhiz/swift,airspeedswift/swift,harlanhaskins/swift,russbishop/swift,deyton/swift,djwbrown/swift,mightydeveloper/swift,kusl/swift,Ivacker/swift,lorentey/swift,CodaFi/swift,deyton/swift,shajrawi/swift,deyton/swift,arvedviehweger/swift,danielmartin/swift,tardieu/swift,khizkhiz/swift,kusl/swift,amraboelela/swift,kusl/swift,sdulal/swift,ken0nek/swift,parkera/swift,jopamer/swift,devincoughlin/swift,xedin/swift,KrishMunot/swift,IngmarStein/swift,dreamsxin/swift,rudkx/swift,cbrentharris/swift,JaSpa/swift,arvedviehweger/swift,emilstahl/swift,ahoppen/swift,ahoppen/swift,adrfer/swift,glessard/swift,cbrentharris/swift,dduan/swift,djwbrown/swift,cbrentharris/swift,LeoShimonaka/swift,sschiau/swift,brentdax/swift,tkremenek/swift,swiftix/swift,return/swift,jckarter/swift,hughbe/swift,tinysun212/swift-windows,OscarSwanros/swift,shahmishal/swift,huonw/swift,harlanhaskins/swift,KrishMunot/swift,gmilos/swift,brentdax/swift,frootloops/swift,calebd/swift,kstaring/swift,xedin/swift,nathawes/swift,MukeshKumarS/Swift,ben-ng/swift,practicalswift/swift,parkera/swift,kentya6/swift,huonw/swift,ken0nek/swift,nathawes/swift,CodaFi/swift,ben-ng/swift,OscarSwanros/swift,danielmartin/swift,emilstahl/swift,LeoShimonaka/swift,brentdax/swift,shahmishal/swift,therealbnut/swift,apple/swift,jtbandes/swift,dduan/swift,Jnosh/swift,swiftix/swift,Ivacker/swift,devincoughlin/swift,ahoppen/swift,Ivacker/swift,lorentey/swift,benlangmuir/swift,sschiau/swift,danielmartin/swift,CodaFi/swift,felix91gr/swift,roambotics/swift,kperryua/swift,IngmarStein/swift,KrishMunot/swift,apple/swift,swiftix/swift.old,deyton/swift,jmgc/swift,calebd/swift,alblue/swift,shahmishal/swift,JGiola/swift,Jnosh/swift,JGiola/swift,LeoShimonaka/swift,CodaFi/swift,lorentey/swift,gribozavr/swift,rudkx/swift,tjw/swift,atrick/swift,jmgc/swift,natecook1000/swift,calebd/swift,brentdax/swift,return/swift,danielmartin/swift,gribozavr/swift,frootloops/swift,zisko/swift,khizkhiz/swift,khizkhiz/swift,austinzheng/swift,kstaring/swift,uasys/swift,huonw/swift,tkremenek/swift,dreamsxin/swift,ben-ng/swift,gottesmm/swift,devincoughlin/swift,mightydeveloper/swift,parkera/swift,johnno1962d/swift,hughbe/swift,tinysun212/swift-windows,hooman/swift,tinysun212/swift-windows,zisko/swift,harlanhaskins/swift,tkremenek/swift,kstaring/swift,manavgabhawala/swift,alblue/swift,manavgabhawala/swift,harlanhaskins/swift,Jnosh/swift,xwu/swift,Jnosh/swift,gmilos/swift,mightydeveloper/swift,allevato/swift,hughbe/swift,Ivacker/swift,sschiau/swift,brentdax/swift,hooman/swift,swiftix/swift.old,JaSpa/swift,kentya6/swift,austinzheng/swift,uasys/swift,modocache/swift,karwa/swift,karwa/swift,zisko/swift,roambotics/swift,milseman/swift,amraboelela/swift,huonw/swift,lorentey/swift,deyton/swift,felix91gr/swift,kentya6/swift,khizkhiz/swift,allevato/swift,JGiola/swift,johnno1962d/swift,hooman/swift,natecook1000/swift,LeoShimonaka/swift,tardieu/swift,jtbandes/swift,apple/swift,karwa/swift,ahoppen/swift,swiftix/swift.old,Ivacker/swift,brentdax/swift,tjw/swift,Ivacker/swift,modocache/swift,allevato/swift,jckarter/swift,roambotics/swift,felix91gr/swift,gribozavr/swift,nathawes/swift,hughbe/swift,hooman/swift,swiftix/swift,brentdax/swift,shahmishal/swift,kstaring/swift,ahoppen/swift,kperryua/swift,tkremenek/swift,gribozavr/swift,adrfer/swift,frootloops/swift,kperryua/swift,modocache/swift,allevato/swift,JaSpa/swift,stephentyrone/swift,hooman/swift,aschwaighofer/swift,swiftix/swift,rudkx/swift,glessard/swift,karwa/swift,gregomni/swift,swiftix/swift.old,uasys/swift,LeoShimonaka/swift,kperryua/swift,manavgabhawala/swift,bitjammer/swift,jopamer/swift,russbishop/swift,CodaFi/swift,manavgabhawala/swift,arvedviehweger/swift,OscarSwanros/swift,frootloops/swift,austinzheng/swift,parkera/swift,slavapestov/swift,jmgc/swift,slavapestov/swift,emilstahl/swift,tkremenek/swift,atrick/swift | text | ## Code Before:
add_swift_library(swiftsimd SHARED IS_STDLIB
simd.swift.gyb
SWIFT_COMPILE_FLAGS -Xfrontend -sil-serialize-all
SWIFT_MODULE_DEPENDS Darwin
INSTALL_IN_COMPONENT stdlib)
## Instruction:
Make the 'simd' module build like the rest of the overlays.
At one point we were considering it to be a replacement rather than an
overlay, but that's not where we are today. We can revisit that later.
Necessary for next commit.
Swift SVN r29438
## Code After:
add_swift_library(swiftsimd IS_SDK_OVERLAY
simd.swift.gyb
SWIFT_COMPILE_FLAGS -Xfrontend -sil-serialize-all
SWIFT_MODULE_DEPENDS Darwin)
|
3bfdd5244238c8c4779c7e95ba685074f98a3c87 | templates/default/server.xml.erb | templates/default/server.xml.erb | <server description="<%= @description %>">
<!-- Enable features -->
<featureManager>
<% @features.each do |feature| -%>
<feature><%= feature %></feature>
<% end -%>
</featureManager>
<% @httpendpoints.each do |httpendpoint| -%>
<httpEndpoint id="<%= httpendpoint["id"] %>"
host="<%= httpendpoint["host"] %>"
httpPort="<%= httpendpoint["httpport"] %>"
httpsPort="<%= httpendpoint["httpsport"] %>"
/>
<% end -%>
<% if @includes != nil && @includes.size > 0 -%>
<% @includes.each do |include| -%>
<include location="<%= include %>" />
<% end -%>
<% end -%>
</server>
| <server description="<%= @description %>">
<!-- Enable features -->
<% if @features != nil && @features.size > 0 -%>
<featureManager>
<% @features.each do |feature| -%>
<feature><%= feature %></feature>
<% end -%>
</featureManager>
<% end -%>
<% if @httpendpoints != nil && @httpendpoints.size > 0 -%>
<% @httpendpoints.each do |httpendpoint| -%>
<httpEndpoint id="<%= httpendpoint["id"] -%>"
<% if httpendpoint["host"] != nil -%> host="<%= httpendpoint["host"] %>" <% end -%>
<% if httpendpoint["httpport"] != nil -%> httpPort="<%= httpendpoint["httpport"] %>" <% end -%>
<% if httpendpoint["httpsport"] != nil -%> httpsPort="<%= httpendpoint["httpsport"] %>" <% end -%>
/>
<% end -%>
<% end -%>
<% if @includes != nil && @includes.size > 0 -%>
<% @includes.each do |include| -%>
<include location="<%= include %>" />
<% end -%>
<% end -%>
</server>
| Update template to make elements and attributes optional. | Update template to make elements and attributes optional.
| HTML+ERB | apache-2.0 | WASdev/ci.chef.wlp,WASdev/ci.chef.wlp | html+erb | ## Code Before:
<server description="<%= @description %>">
<!-- Enable features -->
<featureManager>
<% @features.each do |feature| -%>
<feature><%= feature %></feature>
<% end -%>
</featureManager>
<% @httpendpoints.each do |httpendpoint| -%>
<httpEndpoint id="<%= httpendpoint["id"] %>"
host="<%= httpendpoint["host"] %>"
httpPort="<%= httpendpoint["httpport"] %>"
httpsPort="<%= httpendpoint["httpsport"] %>"
/>
<% end -%>
<% if @includes != nil && @includes.size > 0 -%>
<% @includes.each do |include| -%>
<include location="<%= include %>" />
<% end -%>
<% end -%>
</server>
## Instruction:
Update template to make elements and attributes optional.
## Code After:
<server description="<%= @description %>">
<!-- Enable features -->
<% if @features != nil && @features.size > 0 -%>
<featureManager>
<% @features.each do |feature| -%>
<feature><%= feature %></feature>
<% end -%>
</featureManager>
<% end -%>
<% if @httpendpoints != nil && @httpendpoints.size > 0 -%>
<% @httpendpoints.each do |httpendpoint| -%>
<httpEndpoint id="<%= httpendpoint["id"] -%>"
<% if httpendpoint["host"] != nil -%> host="<%= httpendpoint["host"] %>" <% end -%>
<% if httpendpoint["httpport"] != nil -%> httpPort="<%= httpendpoint["httpport"] %>" <% end -%>
<% if httpendpoint["httpsport"] != nil -%> httpsPort="<%= httpendpoint["httpsport"] %>" <% end -%>
/>
<% end -%>
<% end -%>
<% if @includes != nil && @includes.size > 0 -%>
<% @includes.each do |include| -%>
<include location="<%= include %>" />
<% end -%>
<% end -%>
</server>
|
d23173dc556e3565ee1e2414d1bcab5efe962eb1 | _guides/https.md | _guides/https.md | ---
layout: documentation
title: Protect The Lounge with HTTPS
---
In this guide, we will see how to easily configure The Lounge to be served over [HTTPS](https://en.wikipedia.org/wiki/HTTPS) for better security and privacy.
First, you need an HTTPS certificate. [Let's Encrypt](https://letsencrypt.org/) is a free, automated, and open Certificate Authority that provides completely free HTTPS certificates.
Assuming you have a valid email address at `email@example.com`, and want to serve The Lounge at `https://thelounge.example.com`, run these commands on your server:
```
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt/
./letsencrypt-auto certonly --standalone --email email@example.com -d thelounge.example.com
```
Follow the instructions on screen. This should generate a private key, as well as your HTTPS certificate that will expire after 90 days.
Open your configuration file, located at `${THELOUNGE_HOME}/config.js` and look for the `https` key, and set the following values:
- Change `enable` to `true`
- Set `key` to the private key path that was generated, `privkey.pem`
- Set `certificate` to the certificate path, `fullchain.pem`
Let's Encrypt will create its `/etc/letsencrypt` folder as root user, so you might have to change the owner of these files to the user that runs The Lounge.
| ---
layout: documentation
title: Protect The Lounge with HTTPS
---
In this guide, we will see how to easily configure The Lounge to be served over [HTTPS](https://en.wikipedia.org/wiki/HTTPS) for better security and privacy.
{: .alert.alert-warning role="alert"}
The Lounge only has basic HTTPS support, and will need to be manually to reload certificates on renewal. For advanced HTTPS support, consider [using a reverse proxy](/docs/guides/reverse-proxies.html).
First, you need an HTTPS certificate. [Let's Encrypt](https://letsencrypt.org/) is a free, automated, and open Certificate Authority that provides completely free HTTPS certificates.
Assuming you have a valid email address at `email@example.com`, and want to serve The Lounge at `https://thelounge.example.com`, run these commands on your server:
```
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt/
./letsencrypt-auto certonly --standalone --email email@example.com -d thelounge.example.com
```
Follow the instructions on screen. This should generate a private key, as well as your HTTPS certificate that will expire after 90 days.
Open your configuration file, located at `${THELOUNGE_HOME}/config.js` and look for the `https` key, and set the following values:
- Change `enable` to `true`
- Set `key` to the private key path that was generated, `privkey.pem`
- Set `certificate` to the certificate path, `fullchain.pem`
Let's Encrypt will create its `/etc/letsencrypt` folder as root user, so you might have to change the owner of these files to the user that runs The Lounge.
| Add a note to recommend using a reverse proxy for advanced HTTPS support | Add a note to recommend using a reverse proxy for advanced HTTPS support
| Markdown | mit | thelounge/thelounge.github.io,thelounge/thelounge.github.io,thelounge/thelounge.github.io | markdown | ## Code Before:
---
layout: documentation
title: Protect The Lounge with HTTPS
---
In this guide, we will see how to easily configure The Lounge to be served over [HTTPS](https://en.wikipedia.org/wiki/HTTPS) for better security and privacy.
First, you need an HTTPS certificate. [Let's Encrypt](https://letsencrypt.org/) is a free, automated, and open Certificate Authority that provides completely free HTTPS certificates.
Assuming you have a valid email address at `email@example.com`, and want to serve The Lounge at `https://thelounge.example.com`, run these commands on your server:
```
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt/
./letsencrypt-auto certonly --standalone --email email@example.com -d thelounge.example.com
```
Follow the instructions on screen. This should generate a private key, as well as your HTTPS certificate that will expire after 90 days.
Open your configuration file, located at `${THELOUNGE_HOME}/config.js` and look for the `https` key, and set the following values:
- Change `enable` to `true`
- Set `key` to the private key path that was generated, `privkey.pem`
- Set `certificate` to the certificate path, `fullchain.pem`
Let's Encrypt will create its `/etc/letsencrypt` folder as root user, so you might have to change the owner of these files to the user that runs The Lounge.
## Instruction:
Add a note to recommend using a reverse proxy for advanced HTTPS support
## Code After:
---
layout: documentation
title: Protect The Lounge with HTTPS
---
In this guide, we will see how to easily configure The Lounge to be served over [HTTPS](https://en.wikipedia.org/wiki/HTTPS) for better security and privacy.
{: .alert.alert-warning role="alert"}
The Lounge only has basic HTTPS support, and will need to be manually to reload certificates on renewal. For advanced HTTPS support, consider [using a reverse proxy](/docs/guides/reverse-proxies.html).
First, you need an HTTPS certificate. [Let's Encrypt](https://letsencrypt.org/) is a free, automated, and open Certificate Authority that provides completely free HTTPS certificates.
Assuming you have a valid email address at `email@example.com`, and want to serve The Lounge at `https://thelounge.example.com`, run these commands on your server:
```
git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt/
./letsencrypt-auto certonly --standalone --email email@example.com -d thelounge.example.com
```
Follow the instructions on screen. This should generate a private key, as well as your HTTPS certificate that will expire after 90 days.
Open your configuration file, located at `${THELOUNGE_HOME}/config.js` and look for the `https` key, and set the following values:
- Change `enable` to `true`
- Set `key` to the private key path that was generated, `privkey.pem`
- Set `certificate` to the certificate path, `fullchain.pem`
Let's Encrypt will create its `/etc/letsencrypt` folder as root user, so you might have to change the owner of these files to the user that runs The Lounge.
|
5da75a7bbb2f2b0551b207b6caa635ee28aa6378 | omnibus-test.sh | omnibus-test.sh |
/opt/omnibus-gcc/embedded/bin/gcc --version | grep "4.9.2" |
version=$(cat VERSION)
curl "https://packages.chef.io/files/unstable/omnibus-gcc/${version}/el/6/omnibus-gcc-${version}-1.el6.x86_64.rpm" -O
sudo yum install "omnibus-gcc-${version}-1.el6.x86_64.rpm" -y
rm -f "omnibus-gcc-${version}-1.el6.x86_64.rpm"
/opt/omnibus-gcc/embedded/bin/gcc --version | grep "4.9.2" | Fix test to pull rpm | Fix test to pull rpm
Signed-off-by: Scott Hain <54f99c3933fb11a028e0e31efcf2f4c9707ec4bf@chef.io>
| Shell | apache-2.0 | scotthain/omnibus-gcc,scotthain/omnibus-gcc | shell | ## Code Before:
/opt/omnibus-gcc/embedded/bin/gcc --version | grep "4.9.2"
## Instruction:
Fix test to pull rpm
Signed-off-by: Scott Hain <54f99c3933fb11a028e0e31efcf2f4c9707ec4bf@chef.io>
## Code After:
version=$(cat VERSION)
curl "https://packages.chef.io/files/unstable/omnibus-gcc/${version}/el/6/omnibus-gcc-${version}-1.el6.x86_64.rpm" -O
sudo yum install "omnibus-gcc-${version}-1.el6.x86_64.rpm" -y
rm -f "omnibus-gcc-${version}-1.el6.x86_64.rpm"
/opt/omnibus-gcc/embedded/bin/gcc --version | grep "4.9.2" |
16d6af331e5c5097934a93a4602dcc8d843fff02 | app/views/application_groups/index.html.erb | app/views/application_groups/index.html.erb | <%- model_class = ApplicationGroup -%>
<%t '.title', :default => model_class.model_name.human.pluralize.titleize %>
<div class="page-header">
<%= render 'shared/breadcrumb', crumbs: ['Application Groups'] %>
</div>
<table class="table table-condensed">
<thead>
<tr>
<th>Primary Applicant</th>
<th>No. Applicants</th>
<th>No. Enrollments</th>
<th>Submitted Date</th>
</tr>
</thead>
<% @application_groups.each do |ag| %>
<tbody>
<tr>
<td><%= link_to prepend_glyph_to_name(ag.primary_applicant_id), application_group_path(ag) %> </td>
<td><%= ag.applicants.size %></td>
<td><%= ag.hbx_enrollments.size %></td>
<td><%= ag.submitted_date %></td>
</tr>
</tbody>
<% end %>
</table>
<div class="row">
<div class="col-md-8">
<%= paginate @application_groups, theme: "twitter-bootstrap", pagination_class: "pagination-plain" %>
</div>
<div class="rol-md-4">
<p><%= "#{number_with_delimiter(@application_groups.count)} / #{number_with_delimiter(ApplicationGroup.count)} " %><small>(Application Groups selected / total)</small></p>
</div>
</div>
| <%- model_class = ApplicationGroup -%>
<%t '.title', :default => model_class.model_name.human.pluralize.titleize %>
<div class="page-header">
<%= render 'shared/breadcrumb', crumbs: ['Application Groups'] %>
</div>
<div class="row">
<div class="col-md-offset-8 col-md-4">
<%= render 'shared/search', url: people_path, q: @q, placeholder: "Name, HBX ID, SSN" %>
</div>
</div>
</div>
<%= render "application_group_list", application_groups: @application_groups %>
<div class="row">
<div class="col-md-8">
<%= paginate @application_groups, theme: "twitter-bootstrap", pagination_class: "pagination-plain" %>
</div>
<div class="rol-md-4">
<p><%= "#{number_with_delimiter(@application_groups.count)} / #{number_with_delimiter(ApplicationGroup.count)} " %><small>(Application Groups selected / total)</small></p>
</div>
</div>
| Add search box. Move applicant list to partial | Add search box. Move applicant list to partial
| HTML+ERB | mit | dchbx/gluedb,dchbx/gluedb,dchbx/gluedb,dchbx/gluedb | html+erb | ## Code Before:
<%- model_class = ApplicationGroup -%>
<%t '.title', :default => model_class.model_name.human.pluralize.titleize %>
<div class="page-header">
<%= render 'shared/breadcrumb', crumbs: ['Application Groups'] %>
</div>
<table class="table table-condensed">
<thead>
<tr>
<th>Primary Applicant</th>
<th>No. Applicants</th>
<th>No. Enrollments</th>
<th>Submitted Date</th>
</tr>
</thead>
<% @application_groups.each do |ag| %>
<tbody>
<tr>
<td><%= link_to prepend_glyph_to_name(ag.primary_applicant_id), application_group_path(ag) %> </td>
<td><%= ag.applicants.size %></td>
<td><%= ag.hbx_enrollments.size %></td>
<td><%= ag.submitted_date %></td>
</tr>
</tbody>
<% end %>
</table>
<div class="row">
<div class="col-md-8">
<%= paginate @application_groups, theme: "twitter-bootstrap", pagination_class: "pagination-plain" %>
</div>
<div class="rol-md-4">
<p><%= "#{number_with_delimiter(@application_groups.count)} / #{number_with_delimiter(ApplicationGroup.count)} " %><small>(Application Groups selected / total)</small></p>
</div>
</div>
## Instruction:
Add search box. Move applicant list to partial
## Code After:
<%- model_class = ApplicationGroup -%>
<%t '.title', :default => model_class.model_name.human.pluralize.titleize %>
<div class="page-header">
<%= render 'shared/breadcrumb', crumbs: ['Application Groups'] %>
</div>
<div class="row">
<div class="col-md-offset-8 col-md-4">
<%= render 'shared/search', url: people_path, q: @q, placeholder: "Name, HBX ID, SSN" %>
</div>
</div>
</div>
<%= render "application_group_list", application_groups: @application_groups %>
<div class="row">
<div class="col-md-8">
<%= paginate @application_groups, theme: "twitter-bootstrap", pagination_class: "pagination-plain" %>
</div>
<div class="rol-md-4">
<p><%= "#{number_with_delimiter(@application_groups.count)} / #{number_with_delimiter(ApplicationGroup.count)} " %><small>(Application Groups selected / total)</small></p>
</div>
</div>
|
8e9ecc61bf715a1ad9c7a5fb17ce66df4aa8040b | README.md | README.md | Repo of the bits and pieces of filling your google spreadsheet using a html form and input tags
|
I have been trying to figure this out for a while, and after googling away for the last week and a half or so I think I've been able to put the pieces together on how you can successfully and _unseccurely_ collect **insensitive** user information from your website page and populate a google spreadsheet.
#### Early warning:
In all honestly it might be way easier to just set up a google form and direct users to the form link and have the form submit the results to a spreadsheet.
Also tThis should not under any circumstances be treated as an alternative to a proper database.
That being said, I think this is a very easy and highly customizable way to collect data from different sources and have it fill up a spreadsheet and from there the possibilities are endless.
### Step 1
### Step 2
### Step 3
### Step 4
### Step 5
| Add initial wireframe of the readme | Add initial wireframe of the readme | Markdown | mit | Gideonamani/htmlformgooglesheets,Gideonamani/htmlformgooglesheets | markdown | ## Code Before:
Repo of the bits and pieces of filling your google spreadsheet using a html form and input tags
## Instruction:
Add initial wireframe of the readme
## Code After:
I have been trying to figure this out for a while, and after googling away for the last week and a half or so I think I've been able to put the pieces together on how you can successfully and _unseccurely_ collect **insensitive** user information from your website page and populate a google spreadsheet.
#### Early warning:
In all honestly it might be way easier to just set up a google form and direct users to the form link and have the form submit the results to a spreadsheet.
Also tThis should not under any circumstances be treated as an alternative to a proper database.
That being said, I think this is a very easy and highly customizable way to collect data from different sources and have it fill up a spreadsheet and from there the possibilities are endless.
### Step 1
### Step 2
### Step 3
### Step 4
### Step 5
|
e67b8a59b85259ee8a1bedeb09ea773c78c2f546 | Dnn.AdminExperience/Library/Dnn.PersonaBar.UI/admin/personaBar/scripts/config.js | Dnn.AdminExperience/Library/Dnn.PersonaBar.UI/admin/personaBar/scripts/config.js | 'use strict';
define(['jquery'], function ($) {
return {
init: function () {
var inIframe = window !== window.top && typeof window.top.dnn !== "undefined";
var tabId = inIframe ? window.top.dnn.getVar('sf_tabId') : '';
var siteRoot = inIframe ? window.top.dnn.getVar('sf_siteRoot') : '';
var antiForgeryToken = inIframe ? window.top.document.getElementsByName('__RequestVerificationToken')[0].value : '';
var config = $.extend({}, {
tabId: tabId,
siteRoot: siteRoot,
antiForgeryToken: antiForgeryToken
}, inIframe ? window.parent['personaBarSettings'] : {});
return config;
}
};
}); | 'use strict';
define(['jquery'], function ($) {
return {
init: function () {
var inIframe = window.parent && typeof window.parent.dnn !== "undefined";
var tabId = inIframe ? window.parent.dnn.getVar('sf_tabId') : '';
var siteRoot = inIframe ? window.parent.dnn.getVar('sf_siteRoot') : '';
var antiForgeryToken = inIframe ? window.parent.document.getElementsByName('__RequestVerificationToken')[0].value : '';
var config = $.extend({}, {
tabId: tabId,
siteRoot: siteRoot,
antiForgeryToken: antiForgeryToken
}, inIframe ? window.parent['personaBarSettings'] : {});
return config;
}
};
}); | Fix PersonaBar loading when within an iframe | Fix PersonaBar loading when within an iframe
| JavaScript | mit | dnnsoftware/Dnn.Platform,bdukes/Dnn.Platform,dnnsoftware/Dnn.Platform,mitchelsellers/Dnn.Platform,valadas/Dnn.Platform,mitchelsellers/Dnn.Platform,dnnsoftware/Dnn.Platform,bdukes/Dnn.Platform,bdukes/Dnn.Platform,valadas/Dnn.Platform,nvisionative/Dnn.Platform,dnnsoftware/Dnn.Platform,mitchelsellers/Dnn.Platform,nvisionative/Dnn.Platform,valadas/Dnn.Platform,dnnsoftware/Dnn.Platform,nvisionative/Dnn.Platform,bdukes/Dnn.Platform,mitchelsellers/Dnn.Platform,valadas/Dnn.Platform,valadas/Dnn.Platform,mitchelsellers/Dnn.Platform | javascript | ## Code Before:
'use strict';
define(['jquery'], function ($) {
return {
init: function () {
var inIframe = window !== window.top && typeof window.top.dnn !== "undefined";
var tabId = inIframe ? window.top.dnn.getVar('sf_tabId') : '';
var siteRoot = inIframe ? window.top.dnn.getVar('sf_siteRoot') : '';
var antiForgeryToken = inIframe ? window.top.document.getElementsByName('__RequestVerificationToken')[0].value : '';
var config = $.extend({}, {
tabId: tabId,
siteRoot: siteRoot,
antiForgeryToken: antiForgeryToken
}, inIframe ? window.parent['personaBarSettings'] : {});
return config;
}
};
});
## Instruction:
Fix PersonaBar loading when within an iframe
## Code After:
'use strict';
define(['jquery'], function ($) {
return {
init: function () {
var inIframe = window.parent && typeof window.parent.dnn !== "undefined";
var tabId = inIframe ? window.parent.dnn.getVar('sf_tabId') : '';
var siteRoot = inIframe ? window.parent.dnn.getVar('sf_siteRoot') : '';
var antiForgeryToken = inIframe ? window.parent.document.getElementsByName('__RequestVerificationToken')[0].value : '';
var config = $.extend({}, {
tabId: tabId,
siteRoot: siteRoot,
antiForgeryToken: antiForgeryToken
}, inIframe ? window.parent['personaBarSettings'] : {});
return config;
}
};
}); |
41c54a3402da12615fd37e523efaf92f30544f24 | cliffhanger/app/src/main/java/com/github/charbgr/cliffhanger/shared/extensions/ViewExtensions.kt | cliffhanger/app/src/main/java/com/github/charbgr/cliffhanger/shared/extensions/ViewExtensions.kt | package com.github.charbgr.cliffhanger.shared.extensions
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
fun ViewGroup.render(layoutId: Int, attachToRoot: Boolean = false): View {
return LayoutInflater.from(context).inflate(layoutId, this, attachToRoot)
} | package com.github.charbgr.cliffhanger.shared.extensions
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
fun ViewGroup.render(layoutId: Int, attachToRoot: Boolean = false): View {
return LayoutInflater.from(context).inflate(layoutId, this, attachToRoot)
}
fun View.visibleOrGone(shouldBeVisible: Boolean) {
if (shouldBeVisible) {
this.visible()
} else {
this.gone()
}
}
fun View.visible() {
this.visibility = View.VISIBLE
}
fun View.gone() {
this.visibility = View.GONE
}
| Add visible and gone view extensions | Add visible and gone view extensions
| Kotlin | mit | charbgr/CliffHanger | kotlin | ## Code Before:
package com.github.charbgr.cliffhanger.shared.extensions
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
fun ViewGroup.render(layoutId: Int, attachToRoot: Boolean = false): View {
return LayoutInflater.from(context).inflate(layoutId, this, attachToRoot)
}
## Instruction:
Add visible and gone view extensions
## Code After:
package com.github.charbgr.cliffhanger.shared.extensions
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
fun ViewGroup.render(layoutId: Int, attachToRoot: Boolean = false): View {
return LayoutInflater.from(context).inflate(layoutId, this, attachToRoot)
}
fun View.visibleOrGone(shouldBeVisible: Boolean) {
if (shouldBeVisible) {
this.visible()
} else {
this.gone()
}
}
fun View.visible() {
this.visibility = View.VISIBLE
}
fun View.gone() {
this.visibility = View.GONE
}
|
38ab565ef74832ddb8375b77db8b661fc71cc9f9 | main.go | main.go | package main
import (
"fmt"
"os"
"github.com/kori/surt/pkg"
)
func main() {
switch os.Args[1] {
case "build":
file := os.Args[2]
p := pkg.Prepare(file)
fmt.Println(p.Info.Name)
case "add":
fmt.Println("not implemented yet!")
}
}
| package main
import (
"fmt"
"os"
"github.com/kori/surt/pkg"
)
func main() {
switch os.Args[1] {
default:
fmt.Println("no operation specified")
case "build":
file := os.Args[2]
p := pkg.Build(file)
fmt.Println(p.Info.Name)
case "add":
fmt.Println("not implemented yet!")
}
}
| Add default case to operation switch | Add default case to operation switch
| Go | isc | kori/surt,darthlukan/surt | go | ## Code Before:
package main
import (
"fmt"
"os"
"github.com/kori/surt/pkg"
)
func main() {
switch os.Args[1] {
case "build":
file := os.Args[2]
p := pkg.Prepare(file)
fmt.Println(p.Info.Name)
case "add":
fmt.Println("not implemented yet!")
}
}
## Instruction:
Add default case to operation switch
## Code After:
package main
import (
"fmt"
"os"
"github.com/kori/surt/pkg"
)
func main() {
switch os.Args[1] {
default:
fmt.Println("no operation specified")
case "build":
file := os.Args[2]
p := pkg.Build(file)
fmt.Println(p.Info.Name)
case "add":
fmt.Println("not implemented yet!")
}
}
|
15bc9e70bcf6ec686f0de5b994979963368ed99b | .gitlab-ci.yml | .gitlab-ci.yml | before_script:
- rm -rf /usr/local/go
- apt-get update -qq
- apt-get install -y curl unzip bzip2
- curl -O https://storage.googleapis.com/golang/go1.5.1.linux-amd64.tar.gz
- echo '46eecd290d8803887dec718c691cc243f2175fe0 go1.5.1.linux-amd64.tar.gz' | shasum -c -
- tar -C /usr/local -xzf go1.5.1.linux-amd64.tar.gz
- export PATH=/usr/local/go/bin:$PATH
test:
script: make clean test
| before_script:
- rm -rf /usr/local/go
- apt-get update -qq
- apt-get install -y curl unzip bzip2
- curl -O https://storage.googleapis.com/golang/go1.5.2.linux-amd64.tar.gz
- echo 'cae87ed095e8d94a81871281d35da7829bd1234e go1.5.2.linux-amd64.tar.gz' | shasum -c -
- tar -C /usr/local -xzf go1.5.1.linux-amd64.tar.gz
- export PATH=/usr/local/go/bin:$PATH
test:
script: make clean test
| Use Go 1.5.2 for tests | Use Go 1.5.2 for tests
| YAML | mit | cui-liqiang/gitlab-workhorse | yaml | ## Code Before:
before_script:
- rm -rf /usr/local/go
- apt-get update -qq
- apt-get install -y curl unzip bzip2
- curl -O https://storage.googleapis.com/golang/go1.5.1.linux-amd64.tar.gz
- echo '46eecd290d8803887dec718c691cc243f2175fe0 go1.5.1.linux-amd64.tar.gz' | shasum -c -
- tar -C /usr/local -xzf go1.5.1.linux-amd64.tar.gz
- export PATH=/usr/local/go/bin:$PATH
test:
script: make clean test
## Instruction:
Use Go 1.5.2 for tests
## Code After:
before_script:
- rm -rf /usr/local/go
- apt-get update -qq
- apt-get install -y curl unzip bzip2
- curl -O https://storage.googleapis.com/golang/go1.5.2.linux-amd64.tar.gz
- echo 'cae87ed095e8d94a81871281d35da7829bd1234e go1.5.2.linux-amd64.tar.gz' | shasum -c -
- tar -C /usr/local -xzf go1.5.1.linux-amd64.tar.gz
- export PATH=/usr/local/go/bin:$PATH
test:
script: make clean test
|
71fe1670921371c9a9c861a12972b59700eb8b33 | .github/PULL_REQUEST_TEMPLATE.md | .github/PULL_REQUEST_TEMPLATE.md |
Closes #[the issue number this PR is related to]
<!-- Explain why this change is needed and the solution you propose.
Provide context for others to understand it. -->
#### What should we test?
<!-- List which features should be tested and how. -->
#### Release notes
<!-- Write a one liner description of the change to be included in the release notes.
Every PR is worth mentioning, because you did it for a reason. -->
<!-- Please select one for your PR and delete the other. -->
Changelog Category: User facing changes | Technical changes
#### Dependencies
<!-- Does this PR depend on another one?
Add the link or remove this section. -->
#### Documentation updates
<!-- Are there any wiki pages that need updating after merging this PR?
List them here or remove this section. -->
|
Closes # <!-- Insert issue number here. -->
<!-- Explain why this change is needed and the solution you propose.
Provide context for others to understand it. -->
#### What should we test?
<!-- List which features should be tested and how.
This can be similar to the Steps to Reproduce in the issue.
Also think of other parts of the app which could be affected
by your change. -->
- Visit ... page.
-
#### Release notes
<!-- Please select one for your PR and delete the other. -->
Changelog Category: User facing changes | Technical changes
<!-- Choose a pull request title above which explains your change to a
a user of the Open Food Network app. -->
The title of the pull request will be included in the release notes.
#### Dependencies
<!-- Does this PR depend on another one?
Add the link or remove this section. -->
#### Documentation updates
<!-- Are there any wiki pages that need updating after merging this PR?
List them here or remove this section. -->
| Move release notes to the title of the PR | Move release notes to the title of the PR
Github can generate release notes from titles automatically. That's much easier than us copying the text from each pull request.
Also changed:
- Converted instructions for the issue number to a comment to make pasting the issue number easier.
- More detail for testing instructions. Many people don't fill them out correctly.
- Formatting of comments for better readability. | Markdown | agpl-3.0 | mkllnk/openfoodnetwork,Matt-Yorkley/openfoodnetwork,openfoodfoundation/openfoodnetwork,lin-d-hop/openfoodnetwork,lin-d-hop/openfoodnetwork,openfoodfoundation/openfoodnetwork,Matt-Yorkley/openfoodnetwork,mkllnk/openfoodnetwork,mkllnk/openfoodnetwork,lin-d-hop/openfoodnetwork,Matt-Yorkley/openfoodnetwork,mkllnk/openfoodnetwork,Matt-Yorkley/openfoodnetwork,lin-d-hop/openfoodnetwork,openfoodfoundation/openfoodnetwork,openfoodfoundation/openfoodnetwork | markdown | ## Code Before:
Closes #[the issue number this PR is related to]
<!-- Explain why this change is needed and the solution you propose.
Provide context for others to understand it. -->
#### What should we test?
<!-- List which features should be tested and how. -->
#### Release notes
<!-- Write a one liner description of the change to be included in the release notes.
Every PR is worth mentioning, because you did it for a reason. -->
<!-- Please select one for your PR and delete the other. -->
Changelog Category: User facing changes | Technical changes
#### Dependencies
<!-- Does this PR depend on another one?
Add the link or remove this section. -->
#### Documentation updates
<!-- Are there any wiki pages that need updating after merging this PR?
List them here or remove this section. -->
## Instruction:
Move release notes to the title of the PR
Github can generate release notes from titles automatically. That's much easier than us copying the text from each pull request.
Also changed:
- Converted instructions for the issue number to a comment to make pasting the issue number easier.
- More detail for testing instructions. Many people don't fill them out correctly.
- Formatting of comments for better readability.
## Code After:
Closes # <!-- Insert issue number here. -->
<!-- Explain why this change is needed and the solution you propose.
Provide context for others to understand it. -->
#### What should we test?
<!-- List which features should be tested and how.
This can be similar to the Steps to Reproduce in the issue.
Also think of other parts of the app which could be affected
by your change. -->
- Visit ... page.
-
#### Release notes
<!-- Please select one for your PR and delete the other. -->
Changelog Category: User facing changes | Technical changes
<!-- Choose a pull request title above which explains your change to a
a user of the Open Food Network app. -->
The title of the pull request will be included in the release notes.
#### Dependencies
<!-- Does this PR depend on another one?
Add the link or remove this section. -->
#### Documentation updates
<!-- Are there any wiki pages that need updating after merging this PR?
List them here or remove this section. -->
|
3fbe8a01d93b77b496a28229ffdf3792ebab22c1 | test/helper.js | test/helper.js | var browserify = require('browserify')
var cp = require('child_process')
var envify = require('envify/custom')
var fs = require('fs')
var once = require('once')
var path = require('path')
var CHROME = process.env.CHROME || '/Applications/Google\\ Chrome\\ Canary.app/Contents/MacOS/Google\\ Chrome\\ Canary'
var BUNDLE_PATH = path.join(__dirname, 'chrome-app/bundle.js')
exports.browserify = function (filename, env, cb) {
if (!env) env = {}
if (!cb) cb = function () {}
cb = once(cb)
var b = browserify()
b.add(path.join(__dirname, 'client', filename))
b.transform(envify(env))
b.bundle()
.pipe(fs.createWriteStream(BUNDLE_PATH))
.on('close', cb)
.on('error', cb)
}
exports.launchBrowser = function () {
// chrome 40.0.2188.2 won't open extensions without absolute path.
var app = path.join(__dirname, '..', 'test/chrome-app')
var command = CHROME + ' --load-and-launch-app=' + app
var env = { cwd: path.join(__dirname, '..') }
return cp.exec(command, env, function () {})
}
| var browserify = require('browserify')
var cp = require('child_process')
var envify = require('envify/custom')
var fs = require('fs')
var once = require('once')
var path = require('path')
var CHROME
if (process.env.CHROME) {
CHROME = process.env.CHROME
} else if (process.platform === 'win32') {
CHROME = '"%ProgramFiles(x86)%\\Google\\Chrome\\Application\\chrome.exe"'
} else {
CHROME = '/Applications/Google\\ Chrome\\ Canary.app/Contents/MacOS/Google\\ Chrome\\ Canary'
}
var BUNDLE_PATH = path.join(__dirname, 'chrome-app/bundle.js')
exports.browserify = function (filename, env, cb) {
if (!env) env = {}
if (!cb) cb = function () {}
cb = once(cb)
var b = browserify()
b.add(path.join(__dirname, 'client', filename))
b.transform(envify(env))
b.bundle()
.pipe(fs.createWriteStream(BUNDLE_PATH))
.on('close', cb)
.on('error', cb)
}
exports.launchBrowser = function () {
// chrome 40.0.2188.2 won't open extensions without absolute path.
var app = path.join(__dirname, '..', 'test/chrome-app')
var command = CHROME + ' --load-and-launch-app=' + app
var env = { cwd: path.join(__dirname, '..') }
return cp.exec(command, env, function () {})
}
| Add Chrome path for Windows | tests: Add Chrome path for Windows
| JavaScript | mit | feross/chrome-net,feross/chrome-net | javascript | ## Code Before:
var browserify = require('browserify')
var cp = require('child_process')
var envify = require('envify/custom')
var fs = require('fs')
var once = require('once')
var path = require('path')
var CHROME = process.env.CHROME || '/Applications/Google\\ Chrome\\ Canary.app/Contents/MacOS/Google\\ Chrome\\ Canary'
var BUNDLE_PATH = path.join(__dirname, 'chrome-app/bundle.js')
exports.browserify = function (filename, env, cb) {
if (!env) env = {}
if (!cb) cb = function () {}
cb = once(cb)
var b = browserify()
b.add(path.join(__dirname, 'client', filename))
b.transform(envify(env))
b.bundle()
.pipe(fs.createWriteStream(BUNDLE_PATH))
.on('close', cb)
.on('error', cb)
}
exports.launchBrowser = function () {
// chrome 40.0.2188.2 won't open extensions without absolute path.
var app = path.join(__dirname, '..', 'test/chrome-app')
var command = CHROME + ' --load-and-launch-app=' + app
var env = { cwd: path.join(__dirname, '..') }
return cp.exec(command, env, function () {})
}
## Instruction:
tests: Add Chrome path for Windows
## Code After:
var browserify = require('browserify')
var cp = require('child_process')
var envify = require('envify/custom')
var fs = require('fs')
var once = require('once')
var path = require('path')
var CHROME
if (process.env.CHROME) {
CHROME = process.env.CHROME
} else if (process.platform === 'win32') {
CHROME = '"%ProgramFiles(x86)%\\Google\\Chrome\\Application\\chrome.exe"'
} else {
CHROME = '/Applications/Google\\ Chrome\\ Canary.app/Contents/MacOS/Google\\ Chrome\\ Canary'
}
var BUNDLE_PATH = path.join(__dirname, 'chrome-app/bundle.js')
exports.browserify = function (filename, env, cb) {
if (!env) env = {}
if (!cb) cb = function () {}
cb = once(cb)
var b = browserify()
b.add(path.join(__dirname, 'client', filename))
b.transform(envify(env))
b.bundle()
.pipe(fs.createWriteStream(BUNDLE_PATH))
.on('close', cb)
.on('error', cb)
}
exports.launchBrowser = function () {
// chrome 40.0.2188.2 won't open extensions without absolute path.
var app = path.join(__dirname, '..', 'test/chrome-app')
var command = CHROME + ' --load-and-launch-app=' + app
var env = { cwd: path.join(__dirname, '..') }
return cp.exec(command, env, function () {})
}
|
4844dd00f64240ba371313b21271b07c90ea5b40 | lib/toy_robot_simulator/simulator.rb | lib/toy_robot_simulator/simulator.rb | module ToyRobotSimulator
class Simulator
end
end
| module ToyRobotSimulator
class Simulator
attr_accessor :controller
def initialize
welcome_message
while line = $stdin.gets do
break if line.downcase.include? "quit"
puts line
end
end
def welcome_message
puts %Q(
This is the Toy Robot Simulator Code Challenge!\n
Enter with #{available_commands}\n
or type QUIT to end the simulator! Good game!\n
)
end
def available_commands
["PLACE", "MOVE", "LEFT", "RIGHT"].join(', ')
end
end
end
| Create Simulator with a finite loop that receives commands | Create Simulator with a finite loop that receives commands
| Ruby | mit | fpgentil/toy-robot-simulator | ruby | ## Code Before:
module ToyRobotSimulator
class Simulator
end
end
## Instruction:
Create Simulator with a finite loop that receives commands
## Code After:
module ToyRobotSimulator
class Simulator
attr_accessor :controller
def initialize
welcome_message
while line = $stdin.gets do
break if line.downcase.include? "quit"
puts line
end
end
def welcome_message
puts %Q(
This is the Toy Robot Simulator Code Challenge!\n
Enter with #{available_commands}\n
or type QUIT to end the simulator! Good game!\n
)
end
def available_commands
["PLACE", "MOVE", "LEFT", "RIGHT"].join(', ')
end
end
end
|
a38fc3d53adbfec609d911587e9fa2c5a3e01d92 | workflows/common/sh/sched-titan.sh | workflows/common/sh/sched-titan.sh |
MACHINE="-m cray"
# Swift special setting for Titan
export TITAN=true
# Default PROJECT for CANDLE
export PROJECT=${PROJECT:-CSC249ADOA01}
|
MACHINE="-m cray"
# Swift special setting for Titan
export TITAN=true
# Default PROJECT for CANDLE
#export PROJECT=${PROJECT:-CSC249ADOA01}
export PROJECT=${PROJECT:-MED106}
| Change default project to MED106 for titan | Change default project to MED106 for titan
| Shell | mit | ECP-CANDLE/Supervisor,ECP-CANDLE/Supervisor,ECP-CANDLE/Supervisor,ECP-CANDLE/Supervisor,ECP-CANDLE/Supervisor,ECP-CANDLE/Supervisor | shell | ## Code Before:
MACHINE="-m cray"
# Swift special setting for Titan
export TITAN=true
# Default PROJECT for CANDLE
export PROJECT=${PROJECT:-CSC249ADOA01}
## Instruction:
Change default project to MED106 for titan
## Code After:
MACHINE="-m cray"
# Swift special setting for Titan
export TITAN=true
# Default PROJECT for CANDLE
#export PROJECT=${PROJECT:-CSC249ADOA01}
export PROJECT=${PROJECT:-MED106}
|
210dfcee831a1a59d935c81459d15f9ea6f29f77 | plugins/inputs/system/SWAP_README.md | plugins/inputs/system/SWAP_README.md |
The swap plugin collects system swap metrics.
For a more information on what swap memory is, read [All about Linux swap space](https://www.linux.com/news/all-about-linux-swap-space).
### Configuration:
```toml
# Read metrics about swap memory usage
[[inputs.swap]]
# no configuration
```
### Metrics:
- swap
- fields:
- free (int)
- total (int)
- used (int)
- used_percent (float)
- sin (int)
- sout (int)
### Example Output:
```
swap total=20855394304i,used_percent=45.43883523785713,used=9476448256i,free=1715331072i 1511894782000000000
```
|
The swap plugin collects system swap metrics.
For a more information on what swap memory is, read [All about Linux swap space](https://www.linux.com/news/all-about-linux-swap-space).
### Configuration:
```toml
# Read metrics about swap memory usage
[[inputs.swap]]
# no configuration
```
### Metrics:
- swap
- fields:
- free (int)
- total (int)
- used (int)
- used_percent (float)
- in (int)
- out (int)
### Example Output:
```
swap total=20855394304i,used_percent=45.43883523785713,used=9476448256i,free=1715331072i 1511894782000000000
```
| Fix field name typo in swap documentation | Fix field name typo in swap documentation
| Markdown | mit | puckpuck/telegraf,Heathland/telegraf,marianob85/telegraf,apigee-internal/telegraf,Heathland/telegraf,m4ce/telegraf,influxdb/telegraf,codehate/telegraf,nferch/telegraf,influxdata/telegraf,m4ce/telegraf,signalfx/telegraf,Brightspace/telegraf,mchuang3/telegraf,marianob85/telegraf,schwartzmx/telegraf,li-ang/telegraf,jonaz/telegraf,sebito91/telegraf,codehate/telegraf,schwartzmx/telegraf,sebito91/telegraf,miketonks/telegraf,nferch/telegraf,oldmantaiter/telegraf,codehate/telegraf,oldmantaiter/telegraf,marianob85/telegraf,puckpuck/telegraf,miketonks/telegraf,apigee-internal/telegraf,Heathland/telegraf,srfraser/telegraf,mchuang3/telegraf,codehate/telegraf,influxdb/telegraf,influxdb/telegraf,mchuang3/telegraf,li-ang/telegraf,m4ce/telegraf,influxdata/telegraf,sebito91/telegraf,Brightspace/telegraf,srfraser/telegraf,jonaz/telegraf,schwartzmx/telegraf,li-ang/telegraf,oldmantaiter/telegraf,nferch/telegraf,influxdb/telegraf,srfraser/telegraf,signalfx/telegraf,apigee-internal/telegraf,marianob85/telegraf,puckpuck/telegraf,signalfx/telegraf,miketonks/telegraf,jonaz/telegraf,influxdata/telegraf,Brightspace/telegraf | markdown | ## Code Before:
The swap plugin collects system swap metrics.
For a more information on what swap memory is, read [All about Linux swap space](https://www.linux.com/news/all-about-linux-swap-space).
### Configuration:
```toml
# Read metrics about swap memory usage
[[inputs.swap]]
# no configuration
```
### Metrics:
- swap
- fields:
- free (int)
- total (int)
- used (int)
- used_percent (float)
- sin (int)
- sout (int)
### Example Output:
```
swap total=20855394304i,used_percent=45.43883523785713,used=9476448256i,free=1715331072i 1511894782000000000
```
## Instruction:
Fix field name typo in swap documentation
## Code After:
The swap plugin collects system swap metrics.
For a more information on what swap memory is, read [All about Linux swap space](https://www.linux.com/news/all-about-linux-swap-space).
### Configuration:
```toml
# Read metrics about swap memory usage
[[inputs.swap]]
# no configuration
```
### Metrics:
- swap
- fields:
- free (int)
- total (int)
- used (int)
- used_percent (float)
- in (int)
- out (int)
### Example Output:
```
swap total=20855394304i,used_percent=45.43883523785713,used=9476448256i,free=1715331072i 1511894782000000000
```
|
3bbe9e5aab0bcd51b95b3f718cb790807931d82b | chrome/browser/extensions/extension_message_handler.h | chrome/browser/extensions/extension_message_handler.h | // Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#define CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#pragma once
#include "content/browser/renderer_host/render_view_host_observer.h"
class Profile;
struct ExtensionHostMsg_DomMessage_Params;
// Filters and dispatches extension-related IPC messages that arrive from
// renderer/extension processes. This object is created for renderers and also
// ExtensionHost/BackgroundContents. Contrast this with ExtensionTabHelper,
// which is only created for TabContents.
class ExtensionMessageHandler : public RenderViewHostObserver {
public:
// |sender| is guaranteed to outlive this object.
explicit ExtensionMessageHandler(RenderViewHost* render_view_host);
virtual ~ExtensionMessageHandler();
// RenderViewHostObserver overrides.
virtual bool OnMessageReceived(const IPC::Message& message);
private:
// Message handlers.
void OnPostMessage(int port_id, const std::string& message);
void OnRequest(const ExtensionHostMsg_DomMessage_Params& params);
DISALLOW_COPY_AND_ASSIGN(ExtensionMessageHandler);
};
#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
| // Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#define CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#pragma once
#include "content/browser/renderer_host/render_view_host_observer.h"
class Profile;
struct ExtensionHostMsg_DomMessage_Params;
// Filters and dispatches extension-related IPC messages that arrive from
// renderers. There is one of these objects for each RenderViewHost in Chrome.
// Contrast this with ExtensionTabHelper, which is only created for TabContents.
class ExtensionMessageHandler : public RenderViewHostObserver {
public:
// |sender| is guaranteed to outlive this object.
explicit ExtensionMessageHandler(RenderViewHost* render_view_host);
virtual ~ExtensionMessageHandler();
// RenderViewHostObserver overrides.
virtual bool OnMessageReceived(const IPC::Message& message);
private:
// Message handlers.
void OnPostMessage(int port_id, const std::string& message);
void OnRequest(const ExtensionHostMsg_DomMessage_Params& params);
DISALLOW_COPY_AND_ASSIGN(ExtensionMessageHandler);
};
#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
| Clarify class comment for ExtensionMessageHandler. | Clarify class comment for ExtensionMessageHandler.
TBR=jam@chromium.org
git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@82674 0039d316-1c4b-4281-b951-d872f2087c98
| C | bsd-3-clause | yitian134/chromium,gavinp/chromium,ropik/chromium,adobe/chromium,yitian134/chromium,yitian134/chromium,Crystalnix/house-of-life-chromium,adobe/chromium,ropik/chromium,gavinp/chromium,gavinp/chromium,ropik/chromium,Crystalnix/house-of-life-chromium,yitian134/chromium,ropik/chromium,ropik/chromium,adobe/chromium,adobe/chromium,yitian134/chromium,adobe/chromium,yitian134/chromium,Crystalnix/house-of-life-chromium,Crystalnix/house-of-life-chromium,adobe/chromium,gavinp/chromium,gavinp/chromium,Crystalnix/house-of-life-chromium,gavinp/chromium,Crystalnix/house-of-life-chromium,gavinp/chromium,yitian134/chromium,gavinp/chromium,Crystalnix/house-of-life-chromium,ropik/chromium,Crystalnix/house-of-life-chromium,Crystalnix/house-of-life-chromium,adobe/chromium,Crystalnix/house-of-life-chromium,ropik/chromium,gavinp/chromium,adobe/chromium,Crystalnix/house-of-life-chromium,yitian134/chromium,yitian134/chromium,adobe/chromium,adobe/chromium,gavinp/chromium,yitian134/chromium,adobe/chromium,ropik/chromium,ropik/chromium | c | ## Code Before:
// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#define CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#pragma once
#include "content/browser/renderer_host/render_view_host_observer.h"
class Profile;
struct ExtensionHostMsg_DomMessage_Params;
// Filters and dispatches extension-related IPC messages that arrive from
// renderer/extension processes. This object is created for renderers and also
// ExtensionHost/BackgroundContents. Contrast this with ExtensionTabHelper,
// which is only created for TabContents.
class ExtensionMessageHandler : public RenderViewHostObserver {
public:
// |sender| is guaranteed to outlive this object.
explicit ExtensionMessageHandler(RenderViewHost* render_view_host);
virtual ~ExtensionMessageHandler();
// RenderViewHostObserver overrides.
virtual bool OnMessageReceived(const IPC::Message& message);
private:
// Message handlers.
void OnPostMessage(int port_id, const std::string& message);
void OnRequest(const ExtensionHostMsg_DomMessage_Params& params);
DISALLOW_COPY_AND_ASSIGN(ExtensionMessageHandler);
};
#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
## Instruction:
Clarify class comment for ExtensionMessageHandler.
TBR=jam@chromium.org
git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@82674 0039d316-1c4b-4281-b951-d872f2087c98
## Code After:
// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#define CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
#pragma once
#include "content/browser/renderer_host/render_view_host_observer.h"
class Profile;
struct ExtensionHostMsg_DomMessage_Params;
// Filters and dispatches extension-related IPC messages that arrive from
// renderers. There is one of these objects for each RenderViewHost in Chrome.
// Contrast this with ExtensionTabHelper, which is only created for TabContents.
class ExtensionMessageHandler : public RenderViewHostObserver {
public:
// |sender| is guaranteed to outlive this object.
explicit ExtensionMessageHandler(RenderViewHost* render_view_host);
virtual ~ExtensionMessageHandler();
// RenderViewHostObserver overrides.
virtual bool OnMessageReceived(const IPC::Message& message);
private:
// Message handlers.
void OnPostMessage(int port_id, const std::string& message);
void OnRequest(const ExtensionHostMsg_DomMessage_Params& params);
DISALLOW_COPY_AND_ASSIGN(ExtensionMessageHandler);
};
#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_MESSAGE_HANDLER_H_
|
a18de90de5ef80a1785dea6f2ca1be26e0fddc1d | rootx/src/rootcoreteam.h | rootx/src/rootcoreteam.h |
namespace ROOT {
namespace ROOTX {
//This string will be updated by external script, reading names from http://root.cern.ch/gitstats/authors.html.
//The string has an internal linkage (it has a definition here, not in rootxx.cxx or rootx-cocoa.mm files.
//So this header can be included in different places (as soon as you know what you're doing).
//Please, do not modify this file.
//[STRINGTOREPLACE
const char * gROOTCoreTeam = "Andrei Gheata, Axel Naumann, Bertrand Bellenot, Cristina Cristescu,"
" Danilo Piparo, Fons Rademakers, Gerardo Ganis, Ilka Antcheva,"
" Lorenzo Moneta, Matevz Tadel, Olivier Couet, Paul Russo, Pere Mato,"
" Philippe Canal, Rene Brun, Timur Pocheptsov, Valeri Onuchin,"
" Vassil Vassilev, Wim Lavrijsen, Wouter Verkerke\n\n";
//STRINGTOREPLACE]
}
}
#endif |
namespace ROOT {
namespace ROOTX {
//This string will be updated by external script, reading names from http://root.cern.ch/gitstats/authors.html.
//The names are sorted in alphabetical order.
//The string has an internal linkage (it has a definition here, not in rootxx.cxx or rootx-cocoa.mm files.
//So this header can be included in different places (as soon as you know what you're doing).
//Please, do not modify this file.
const char * gROOTCoreTeam =
//[STRINGTOREPLACE
"Andrei Gheata, Axel Naumann, Bertrand Bellenot, Cristina Cristescu,"
" Danilo Piparo, Fons Rademakers, Gerardo Ganis, Ilka Antcheva,"
" Lorenzo Moneta, Matevz Tadel, Olivier Couet, Paul Russo, Pere Mato,"
" Philippe Canal, Rene Brun, Timur Pocheptsov, Valeri Onuchin,"
" Vassil Vassilev, Wim Lavrijsen, Wouter Verkerke.\n\n";
//STRINGTOREPLACE]
}
}
#endif | Make it even simpler for a script to replace. | Make it even simpler for a script to replace.
| C | lgpl-2.1 | CristinaCristescu/root,esakellari/root,0x0all/ROOT,smarinac/root,pspe/root,lgiommi/root,davidlt/root,arch1tect0r/root,pspe/root,vukasinmilosevic/root,satyarth934/root,mhuwiler/rootauto,Y--/root,krafczyk/root,krafczyk/root,Y--/root,sawenzel/root,zzxuanyuan/root,satyarth934/root,zzxuanyuan/root-compressor-dummy,sbinet/cxx-root,davidlt/root,thomaskeck/root,buuck/root,sawenzel/root,omazapa/root-old,omazapa/root,arch1tect0r/root,mkret2/root,beniz/root,agarciamontoro/root,gbitzes/root,sbinet/cxx-root,sawenzel/root,gbitzes/root,perovic/root,zzxuanyuan/root,gbitzes/root,omazapa/root-old,pspe/root,agarciamontoro/root,esakellari/root,beniz/root,gganis/root,georgtroska/root,veprbl/root,Duraznos/root,olifre/root,esakellari/root,pspe/root,sirinath/root,veprbl/root,veprbl/root,evgeny-boger/root,olifre/root,lgiommi/root,BerserkerTroll/root,omazapa/root,Y--/root,evgeny-boger/root,karies/root,sirinath/root,perovic/root,omazapa/root-old,satyarth934/root,mkret2/root,gganis/root,olifre/root,mattkretz/root,simonpf/root,krafczyk/root,dfunke/root,zzxuanyuan/root,zzxuanyuan/root,mattkretz/root,nilqed/root,0x0all/ROOT,nilqed/root,sbinet/cxx-root,davidlt/root,mkret2/root,perovic/root,abhinavmoudgil95/root,omazapa/root,abhinavmoudgil95/root,esakellari/root,omazapa/root,vukasinmilosevic/root,simonpf/root,sawenzel/root,sirinath/root,gbitzes/root,gbitzes/root,nilqed/root,pspe/root,sirinath/root,Duraznos/root,CristinaCristescu/root,davidlt/root,0x0all/ROOT,root-mirror/root,beniz/root,evgeny-boger/root,esakellari/my_root_for_test,georgtroska/root,georgtroska/root,vukasinmilosevic/root,sirinath/root,mattkretz/root,jrtomps/root,thomaskeck/root,mattkretz/root,agarciamontoro/root,arch1tect0r/root,Duraznos/root,krafczyk/root,georgtroska/root,buuck/root,arch1tect0r/root,gbitzes/root,jrtomps/root,agarciamontoro/root,arch1tect0r/root,zzxuanyuan/root-compressor-dummy,jrtomps/root,karies/root,krafczyk/root,CristinaCristescu/root,omazapa/root,BerserkerTroll/root,root-mirror/root,veprbl/root,lgiommi/root,omazapa/root-old,gbitzes/root,mattkretz/root,lgiommi/root,vukasinmilosevic/root,lgiommi/root,evgeny-boger/root,veprbl/root,mkret2/root,beniz/root,krafczyk/root,BerserkerTroll/root,agarciamontoro/root,perovic/root,satyarth934/root,georgtroska/root,mattkretz/root,BerserkerTroll/root,gganis/root,davidlt/root,lgiommi/root,olifre/root,jrtomps/root,root-mirror/root,Duraznos/root,BerserkerTroll/root,buuck/root,arch1tect0r/root,vukasinmilosevic/root,buuck/root,zzxuanyuan/root,simonpf/root,sbinet/cxx-root,BerserkerTroll/root,dfunke/root,satyarth934/root,arch1tect0r/root,beniz/root,perovic/root,omazapa/root-old,simonpf/root,olifre/root,dfunke/root,davidlt/root,bbockelm/root,smarinac/root,perovic/root,0x0all/ROOT,olifre/root,sirinath/root,Duraznos/root,beniz/root,veprbl/root,evgeny-boger/root,zzxuanyuan/root-compressor-dummy,simonpf/root,CristinaCristescu/root,gbitzes/root,gganis/root,arch1tect0r/root,BerserkerTroll/root,pspe/root,nilqed/root,vukasinmilosevic/root,root-mirror/root,buuck/root,root-mirror/root,gganis/root,perovic/root,pspe/root,pspe/root,esakellari/my_root_for_test,abhinavmoudgil95/root,sbinet/cxx-root,nilqed/root,bbockelm/root,abhinavmoudgil95/root,Y--/root,mhuwiler/rootauto,omazapa/root-old,abhinavmoudgil95/root,bbockelm/root,thomaskeck/root,buuck/root,karies/root,dfunke/root,esakellari/my_root_for_test,jrtomps/root,abhinavmoudgil95/root,simonpf/root,omazapa/root-old,esakellari/my_root_for_test,root-mirror/root,davidlt/root,karies/root,perovic/root,Y--/root,esakellari/root,esakellari/root,sawenzel/root,agarciamontoro/root,mhuwiler/rootauto,mhuwiler/rootauto,zzxuanyuan/root-compressor-dummy,mattkretz/root,zzxuanyuan/root,Y--/root,olifre/root,gbitzes/root,lgiommi/root,agarciamontoro/root,vukasinmilosevic/root,simonpf/root,pspe/root,Y--/root,esakellari/my_root_for_test,beniz/root,root-mirror/root,vukasinmilosevic/root,sirinath/root,davidlt/root,jrtomps/root,satyarth934/root,lgiommi/root,sbinet/cxx-root,CristinaCristescu/root,satyarth934/root,0x0all/ROOT,sawenzel/root,mkret2/root,vukasinmilosevic/root,dfunke/root,sbinet/cxx-root,satyarth934/root,smarinac/root,nilqed/root,georgtroska/root,veprbl/root,arch1tect0r/root,bbockelm/root,0x0all/ROOT,karies/root,bbockelm/root,thomaskeck/root,CristinaCristescu/root,smarinac/root,thomaskeck/root,CristinaCristescu/root,mattkretz/root,simonpf/root,abhinavmoudgil95/root,dfunke/root,evgeny-boger/root,mhuwiler/rootauto,esakellari/my_root_for_test,esakellari/root,pspe/root,Duraznos/root,evgeny-boger/root,nilqed/root,zzxuanyuan/root,zzxuanyuan/root,zzxuanyuan/root-compressor-dummy,beniz/root,nilqed/root,lgiommi/root,sirinath/root,nilqed/root,gganis/root,jrtomps/root,veprbl/root,bbockelm/root,esakellari/root,olifre/root,perovic/root,buuck/root,mkret2/root,lgiommi/root,perovic/root,pspe/root,omazapa/root-old,0x0all/ROOT,beniz/root,mkret2/root,root-mirror/root,BerserkerTroll/root,sirinath/root,krafczyk/root,gbitzes/root,smarinac/root,root-mirror/root,omazapa/root,sawenzel/root,thomaskeck/root,esakellari/my_root_for_test,sawenzel/root,smarinac/root,satyarth934/root,zzxuanyuan/root,abhinavmoudgil95/root,bbockelm/root,sirinath/root,mkret2/root,veprbl/root,abhinavmoudgil95/root,thomaskeck/root,davidlt/root,karies/root,evgeny-boger/root,BerserkerTroll/root,omazapa/root-old,beniz/root,BerserkerTroll/root,jrtomps/root,karies/root,Y--/root,dfunke/root,mhuwiler/rootauto,simonpf/root,esakellari/my_root_for_test,zzxuanyuan/root-compressor-dummy,mhuwiler/rootauto,zzxuanyuan/root,gganis/root,gganis/root,Duraznos/root,veprbl/root,sawenzel/root,agarciamontoro/root,omazapa/root-old,BerserkerTroll/root,CristinaCristescu/root,gbitzes/root,krafczyk/root,thomaskeck/root,buuck/root,lgiommi/root,georgtroska/root,gganis/root,mhuwiler/rootauto,mattkretz/root,nilqed/root,mkret2/root,sbinet/cxx-root,beniz/root,perovic/root,davidlt/root,sirinath/root,jrtomps/root,karies/root,jrtomps/root,mkret2/root,Y--/root,smarinac/root,sbinet/cxx-root,evgeny-boger/root,bbockelm/root,zzxuanyuan/root,Duraznos/root,mhuwiler/rootauto,omazapa/root,nilqed/root,bbockelm/root,karies/root,agarciamontoro/root,georgtroska/root,gganis/root,mhuwiler/rootauto,sbinet/cxx-root,karies/root,0x0all/ROOT,arch1tect0r/root,sawenzel/root,smarinac/root,omazapa/root,gganis/root,zzxuanyuan/root-compressor-dummy,zzxuanyuan/root-compressor-dummy,abhinavmoudgil95/root,buuck/root,dfunke/root,thomaskeck/root,krafczyk/root,Y--/root,davidlt/root,bbockelm/root,0x0all/ROOT,evgeny-boger/root,jrtomps/root,sawenzel/root,Duraznos/root,dfunke/root,esakellari/my_root_for_test,veprbl/root,mkret2/root,Duraznos/root,satyarth934/root,georgtroska/root,buuck/root,simonpf/root,mattkretz/root,dfunke/root,Y--/root,bbockelm/root,arch1tect0r/root,root-mirror/root,CristinaCristescu/root,omazapa/root-old,sbinet/cxx-root,Duraznos/root,vukasinmilosevic/root,abhinavmoudgil95/root,thomaskeck/root,agarciamontoro/root,olifre/root,esakellari/root,karies/root,dfunke/root,krafczyk/root,mattkretz/root,smarinac/root,georgtroska/root,evgeny-boger/root,simonpf/root,olifre/root,smarinac/root,esakellari/root,agarciamontoro/root,zzxuanyuan/root-compressor-dummy,zzxuanyuan/root,olifre/root,vukasinmilosevic/root,esakellari/my_root_for_test,georgtroska/root,omazapa/root,omazapa/root,root-mirror/root,CristinaCristescu/root,satyarth934/root,zzxuanyuan/root-compressor-dummy,krafczyk/root,buuck/root,omazapa/root,zzxuanyuan/root-compressor-dummy,mhuwiler/rootauto,CristinaCristescu/root,esakellari/root | c | ## Code Before:
namespace ROOT {
namespace ROOTX {
//This string will be updated by external script, reading names from http://root.cern.ch/gitstats/authors.html.
//The string has an internal linkage (it has a definition here, not in rootxx.cxx or rootx-cocoa.mm files.
//So this header can be included in different places (as soon as you know what you're doing).
//Please, do not modify this file.
//[STRINGTOREPLACE
const char * gROOTCoreTeam = "Andrei Gheata, Axel Naumann, Bertrand Bellenot, Cristina Cristescu,"
" Danilo Piparo, Fons Rademakers, Gerardo Ganis, Ilka Antcheva,"
" Lorenzo Moneta, Matevz Tadel, Olivier Couet, Paul Russo, Pere Mato,"
" Philippe Canal, Rene Brun, Timur Pocheptsov, Valeri Onuchin,"
" Vassil Vassilev, Wim Lavrijsen, Wouter Verkerke\n\n";
//STRINGTOREPLACE]
}
}
#endif
## Instruction:
Make it even simpler for a script to replace.
## Code After:
namespace ROOT {
namespace ROOTX {
//This string will be updated by external script, reading names from http://root.cern.ch/gitstats/authors.html.
//The names are sorted in alphabetical order.
//The string has an internal linkage (it has a definition here, not in rootxx.cxx or rootx-cocoa.mm files.
//So this header can be included in different places (as soon as you know what you're doing).
//Please, do not modify this file.
const char * gROOTCoreTeam =
//[STRINGTOREPLACE
"Andrei Gheata, Axel Naumann, Bertrand Bellenot, Cristina Cristescu,"
" Danilo Piparo, Fons Rademakers, Gerardo Ganis, Ilka Antcheva,"
" Lorenzo Moneta, Matevz Tadel, Olivier Couet, Paul Russo, Pere Mato,"
" Philippe Canal, Rene Brun, Timur Pocheptsov, Valeri Onuchin,"
" Vassil Vassilev, Wim Lavrijsen, Wouter Verkerke.\n\n";
//STRINGTOREPLACE]
}
}
#endif |
a21b91f5b0caff1bc32862f84a57166840fc047c | key_dates.html | key_dates.html | ---
layout: main
---
<h1>Key Dates for SR{{ site.sr.year }}</h1>
<h2>Kickstart</h2>
<p><a href="/events/kickstart">Kickstart</a> is when you will learn about the game, and receive the kit.</p>
<p>For SR{{ site.sr.year }} the dates are as below. We expect to confirm the particulars of each event at the start of the academic year.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list kickstart, branch, Not hosted here, true %}
{% endfor %}
<h2>Tech Days</h2>
<p><a href="/events/tech_days">Tech Days</a> take place throughout the year to help you along with the design and development of your robot.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list tech_day, branch, TBA, true %}
{% endfor %}
<h2>Competition</h2>
{% events_list competition, all, Date TBC, true %}
| ---
layout: main
title: Key Dates
---
<h1>Key Dates for SR{{ site.sr.year }}</h1>
<h2>Kickstart</h2>
<p><a href="/events/kickstart">Kickstart</a> is when you will learn about the game, and receive the kit.</p>
<p>For SR{{ site.sr.year }} the dates are as below. We expect to confirm the particulars of each event at the start of the academic year.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list kickstart, branch, Not hosted here, true %}
{% endfor %}
<h2>Tech Days</h2>
<p><a href="/events/tech_days">Tech Days</a> take place throughout the year to help you along with the design and development of your robot.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list tech_day, branch, TBA, true %}
{% endfor %}
<h2>Competition</h2>
{% events_list competition, all, Date TBC, true %}
| Add a title to the key dates page | Add a title to the key dates page
| HTML | mit | prophile/srweb-jekyll,prophile/srweb-jekyll,prophile/srweb-jekyll,PeterJCLaw/srweb-jekyll,PeterJCLaw/srweb-jekyll,prophile/srweb-jekyll,prophile/srweb-jekyll,PeterJCLaw/srweb-jekyll,PeterJCLaw/srweb-jekyll,prophile/srweb-jekyll,PeterJCLaw/srweb-jekyll,PeterJCLaw/srweb-jekyll | html | ## Code Before:
---
layout: main
---
<h1>Key Dates for SR{{ site.sr.year }}</h1>
<h2>Kickstart</h2>
<p><a href="/events/kickstart">Kickstart</a> is when you will learn about the game, and receive the kit.</p>
<p>For SR{{ site.sr.year }} the dates are as below. We expect to confirm the particulars of each event at the start of the academic year.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list kickstart, branch, Not hosted here, true %}
{% endfor %}
<h2>Tech Days</h2>
<p><a href="/events/tech_days">Tech Days</a> take place throughout the year to help you along with the design and development of your robot.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list tech_day, branch, TBA, true %}
{% endfor %}
<h2>Competition</h2>
{% events_list competition, all, Date TBC, true %}
## Instruction:
Add a title to the key dates page
## Code After:
---
layout: main
title: Key Dates
---
<h1>Key Dates for SR{{ site.sr.year }}</h1>
<h2>Kickstart</h2>
<p><a href="/events/kickstart">Kickstart</a> is when you will learn about the game, and receive the kit.</p>
<p>For SR{{ site.sr.year }} the dates are as below. We expect to confirm the particulars of each event at the start of the academic year.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list kickstart, branch, Not hosted here, true %}
{% endfor %}
<h2>Tech Days</h2>
<p><a href="/events/tech_days">Tech Days</a> take place throughout the year to help you along with the design and development of your robot.</p>
{% for branch in site.sr.branches %}
<h3>{{ branch }}</h3>
{% events_list tech_day, branch, TBA, true %}
{% endfor %}
<h2>Competition</h2>
{% events_list competition, all, Date TBC, true %}
|
fc5652591c650d502598479f487496a642b1ca31 | README.md | README.md | Wikipedia-based Explicit Semantic Analysis, as described by Gabrilovich and Markovich
| Wikipedia-based Explicit Semantic Analysis, as described by Gabrilovich and Markovitch.
ESA is well described in a scientific paper.
http://en.wikipedia.org/wiki/Explicit_semantic_analysis
http://www.cs.technion.ac.il/~gabr/resources/code/esa/esa.html
http://www.cs.technion.ac.il/~gabr/papers/ijcai-2007-sim.pdf
| Update readme with links to more resources. | Update readme with links to more resources. | Markdown | agpl-3.0 | pvoosten/explicit-semantic-analysis | markdown | ## Code Before:
Wikipedia-based Explicit Semantic Analysis, as described by Gabrilovich and Markovich
## Instruction:
Update readme with links to more resources.
## Code After:
Wikipedia-based Explicit Semantic Analysis, as described by Gabrilovich and Markovitch.
ESA is well described in a scientific paper.
http://en.wikipedia.org/wiki/Explicit_semantic_analysis
http://www.cs.technion.ac.il/~gabr/resources/code/esa/esa.html
http://www.cs.technion.ac.il/~gabr/papers/ijcai-2007-sim.pdf
|
3ed14bcd364d1843e35cd4a6d1bd48e06379c223 | linter.py | linter.py |
"""This module exports the Hlint plugin class."""
from SublimeLinter.lint import Linter
class Hlint(Linter):
"""Provides an interface to hlint."""
defaults = {
'selector': 'source.haskell'
}
cmd = 'hlint'
regex = (
r'^.+:(?P<line>\d+):'
'(?P<col>\d+):\s*'
'(?:(?P<error>Error)|(?P<warning>Warning)):\s*'
'(?P<message>.+)$'
)
multiline = True
tempfile_suffix = 'hs'
|
"""This module exports the Hlint plugin class."""
import json
from SublimeLinter.lint import Linter, LintMatch
class Hlint(Linter):
"""Provides an interface to hlint."""
cmd = 'hlint ${args} --json -'
defaults = {
'selector': 'source.haskell'
}
def find_errors(self, output):
# type: (str) -> Iterator[LintMatch]
errors = json.loads(output)
for error in errors:
message = "{hint}. Found: {from}".format(**error)
if error['to']:
message += " Perhaps: {to}".format(**error)
yield LintMatch(
error_type=error['severity'].lower(),
line=error['startLine'] - 1,
col=error['startColumn'] - 1,
message=message
)
| Use JSON to parse hlint output | Use JSON to parse hlint output
| Python | mit | SublimeLinter/SublimeLinter-hlint | python | ## Code Before:
"""This module exports the Hlint plugin class."""
from SublimeLinter.lint import Linter
class Hlint(Linter):
"""Provides an interface to hlint."""
defaults = {
'selector': 'source.haskell'
}
cmd = 'hlint'
regex = (
r'^.+:(?P<line>\d+):'
'(?P<col>\d+):\s*'
'(?:(?P<error>Error)|(?P<warning>Warning)):\s*'
'(?P<message>.+)$'
)
multiline = True
tempfile_suffix = 'hs'
## Instruction:
Use JSON to parse hlint output
## Code After:
"""This module exports the Hlint plugin class."""
import json
from SublimeLinter.lint import Linter, LintMatch
class Hlint(Linter):
"""Provides an interface to hlint."""
cmd = 'hlint ${args} --json -'
defaults = {
'selector': 'source.haskell'
}
def find_errors(self, output):
# type: (str) -> Iterator[LintMatch]
errors = json.loads(output)
for error in errors:
message = "{hint}. Found: {from}".format(**error)
if error['to']:
message += " Perhaps: {to}".format(**error)
yield LintMatch(
error_type=error['severity'].lower(),
line=error['startLine'] - 1,
col=error['startColumn'] - 1,
message=message
)
|
f3696c9dc77ee6e52b563174f85d8c6457283128 | lib/git_trend.rb | lib/git_trend.rb | require "git_trend/cli"
require "git_trend/formatter"
require "git_trend/formatters/text_formatter"
require "git_trend/formatters/json_formatter"
require "git_trend/project"
require "git_trend/scraper"
require "git_trend/version"
module GitTrend
# GitTrend.get
# GitTrend.get('ruby')
# GitTrend.get(:ruby)
#
# GitTrend.get(since: :weekly)
# GitTrend.get(since: :week)
# GitTrend.get(since: :w)
#
# GitTrend.get('ruby', 'weekly')
# GitTrend.get(:ruby, :weekly)
# GitTrend.get(language: :ruby, since: :weekly)
def self.get(*opts)
if opts[0].instance_of?(Hash)
hash = opts[0]
language = hash.key?(:language) ? hash[:language] : nil
since = hash.key?(:since) ? hash[:since] : nil
Scraper.new.get(language, since)
else
Scraper.new.get(*opts)
end
end
def self.languages
Scraper.new.languages
end
end
| require "git_trend/cli"
require "git_trend/formatter"
require "git_trend/formatters/text_formatter"
require "git_trend/formatters/json_formatter"
require "git_trend/project"
require "git_trend/scraper"
require "git_trend/version"
module GitTrend
# GitTrend.get
# GitTrend.get('ruby')
# GitTrend.get(:ruby)
#
# GitTrend.get(since: :weekly)
# GitTrend.get(since: :week)
# GitTrend.get(since: :w)
#
# GitTrend.get('ruby', 'weekly')
# GitTrend.get(:ruby, :weekly)
# GitTrend.get(language: :ruby, since: :weekly)
def self.get(*opts)
if opts[0].instance_of?(Hash)
opt = opts[0]
Scraper.new.get(opt[:language], opt[:since])
else
Scraper.new.get(*opts)
end
end
def self.languages
Scraper.new.languages
end
end
| Refactor to simlify arguments handling | Refactor to simlify arguments handling
| Ruby | mit | rochefort/git-trend,rochefort/git-trend | ruby | ## Code Before:
require "git_trend/cli"
require "git_trend/formatter"
require "git_trend/formatters/text_formatter"
require "git_trend/formatters/json_formatter"
require "git_trend/project"
require "git_trend/scraper"
require "git_trend/version"
module GitTrend
# GitTrend.get
# GitTrend.get('ruby')
# GitTrend.get(:ruby)
#
# GitTrend.get(since: :weekly)
# GitTrend.get(since: :week)
# GitTrend.get(since: :w)
#
# GitTrend.get('ruby', 'weekly')
# GitTrend.get(:ruby, :weekly)
# GitTrend.get(language: :ruby, since: :weekly)
def self.get(*opts)
if opts[0].instance_of?(Hash)
hash = opts[0]
language = hash.key?(:language) ? hash[:language] : nil
since = hash.key?(:since) ? hash[:since] : nil
Scraper.new.get(language, since)
else
Scraper.new.get(*opts)
end
end
def self.languages
Scraper.new.languages
end
end
## Instruction:
Refactor to simlify arguments handling
## Code After:
require "git_trend/cli"
require "git_trend/formatter"
require "git_trend/formatters/text_formatter"
require "git_trend/formatters/json_formatter"
require "git_trend/project"
require "git_trend/scraper"
require "git_trend/version"
module GitTrend
# GitTrend.get
# GitTrend.get('ruby')
# GitTrend.get(:ruby)
#
# GitTrend.get(since: :weekly)
# GitTrend.get(since: :week)
# GitTrend.get(since: :w)
#
# GitTrend.get('ruby', 'weekly')
# GitTrend.get(:ruby, :weekly)
# GitTrend.get(language: :ruby, since: :weekly)
def self.get(*opts)
if opts[0].instance_of?(Hash)
opt = opts[0]
Scraper.new.get(opt[:language], opt[:since])
else
Scraper.new.get(*opts)
end
end
def self.languages
Scraper.new.languages
end
end
|
aa1a7a8b481411f027d3931a2d52382398345ac1 | tests/test-x509.c | tests/test-x509.c | static void
test_extract_subject (void)
{
char *subject;
subject = mongoc_ssl_extract_subject (CERT_SERVER, NULL);
ASSERT_CMPSTR (subject, "C=IS,ST=Reykjavik,L=Reykjavik,O=MongoDB,OU=Drivers,CN=server");
bson_free (subject);
subject = mongoc_ssl_extract_subject (CERT_CLIENT, NULL);
ASSERT_CMPSTR (subject, "C=IS,ST=Kopavogur,L=Kopavogur,O=MongoDB,OU=Drivers,CN=client");
bson_free (subject);
}
#endif
void
test_x509_install (TestSuite *suite)
{
#ifdef MONGOC_ENABLE_OPENSSL
TestSuite_Add (suite, "/X509/extract_subject", test_extract_subject);
#endif
}
| static void
test_extract_subject (void)
{
char *subject;
subject = mongoc_ssl_extract_subject (CERT_SERVER, NULL);
ASSERT_CMPSTR (subject, "C=US,ST=California,L=Palo Alto,O=MongoDB,OU=Drivers,CN=server");
bson_free (subject);
subject = mongoc_ssl_extract_subject (CERT_CLIENT, NULL);
ASSERT_CMPSTR (subject, "C=NO,ST=Oslo,L=Oslo,O=MongoDB,OU=Drivers,CN=client");
bson_free (subject);
}
#endif
void
test_x509_install (TestSuite *suite)
{
#ifdef MONGOC_ENABLE_OPENSSL
TestSuite_Add (suite, "/X509/extract_subject", test_extract_subject);
#endif
}
| Fix last-minute certificate subject changes | Fix last-minute certificate subject changes
| C | apache-2.0 | christopherjwang/mongo-c-driver,mongodb/mongo-c-driver,bjori/mongo-c-driver,ajdavis/mongo-c-driver,ajdavis/mongo-c-driver,beingmeta/mongo-c-driver,jmikola/mongo-c-driver,ajdavis/mongo-c-driver,mongodb/mongo-c-driver,acmorrow/mongo-c-driver,Machyne/mongo-c-driver,rcsanchez97/mongo-c-driver,christopherjwang/mongo-c-driver,Machyne/mongo-c-driver,Machyne/mongo-c-driver,acmorrow/mongo-c-driver,jmikola/mongo-c-driver,remicollet/mongo-c-driver,bjori/mongo-c-driver,bjori/mongo-c-driver,jmikola/mongo-c-driver,bjori/mongo-c-driver,Convey-Compliance/mongo-c-driver,Convey-Compliance/mongo-c-driver,mschoenlaub/mongo-c-driver,mschoenlaub/mongo-c-driver,christopherjwang/mongo-c-driver,bjori/mongo-c-driver,remicollet/mongo-c-driver,derickr/mongo-c-driver,ajdavis/mongo-c-driver,jmikola/mongo-c-driver,remicollet/mongo-c-driver,remicollet/mongo-c-driver,beingmeta/mongo-c-driver,rcsanchez97/mongo-c-driver,beingmeta/mongo-c-driver,mongodb/mongo-c-driver,mschoenlaub/mongo-c-driver,Machyne/mongo-c-driver,beingmeta/mongo-c-driver,ajdavis/mongo-c-driver,ajdavis/mongo-c-driver,jmikola/mongo-c-driver,bjori/mongo-c-driver,rcsanchez97/mongo-c-driver,jmikola/mongo-c-driver,malexzx/mongo-c-driver,rcsanchez97/mongo-c-driver,malexzx/mongo-c-driver,derickr/mongo-c-driver,remicollet/mongo-c-driver,derickr/mongo-c-driver,acmorrow/mongo-c-driver,Convey-Compliance/mongo-c-driver,derickr/mongo-c-driver,mongodb/mongo-c-driver,malexzx/mongo-c-driver,derickr/mongo-c-driver,acmorrow/mongo-c-driver,mschoenlaub/mongo-c-driver,malexzx/mongo-c-driver,acmorrow/mongo-c-driver,derickr/mongo-c-driver,beingmeta/mongo-c-driver,Convey-Compliance/mongo-c-driver,bjori/mongo-c-driver,mongodb/mongo-c-driver,derickr/mongo-c-driver,ajdavis/mongo-c-driver,rcsanchez97/mongo-c-driver,rcsanchez97/mongo-c-driver,beingmeta/mongo-c-driver,jmikola/mongo-c-driver,beingmeta/mongo-c-driver,remicollet/mongo-c-driver,remicollet/mongo-c-driver,beingmeta/mongo-c-driver,christopherjwang/mongo-c-driver,acmorrow/mongo-c-driver,acmorrow/mongo-c-driver,mongodb/mongo-c-driver,Convey-Compliance/mongo-c-driver,mongodb/mongo-c-driver,rcsanchez97/mongo-c-driver | c | ## Code Before:
static void
test_extract_subject (void)
{
char *subject;
subject = mongoc_ssl_extract_subject (CERT_SERVER, NULL);
ASSERT_CMPSTR (subject, "C=IS,ST=Reykjavik,L=Reykjavik,O=MongoDB,OU=Drivers,CN=server");
bson_free (subject);
subject = mongoc_ssl_extract_subject (CERT_CLIENT, NULL);
ASSERT_CMPSTR (subject, "C=IS,ST=Kopavogur,L=Kopavogur,O=MongoDB,OU=Drivers,CN=client");
bson_free (subject);
}
#endif
void
test_x509_install (TestSuite *suite)
{
#ifdef MONGOC_ENABLE_OPENSSL
TestSuite_Add (suite, "/X509/extract_subject", test_extract_subject);
#endif
}
## Instruction:
Fix last-minute certificate subject changes
## Code After:
static void
test_extract_subject (void)
{
char *subject;
subject = mongoc_ssl_extract_subject (CERT_SERVER, NULL);
ASSERT_CMPSTR (subject, "C=US,ST=California,L=Palo Alto,O=MongoDB,OU=Drivers,CN=server");
bson_free (subject);
subject = mongoc_ssl_extract_subject (CERT_CLIENT, NULL);
ASSERT_CMPSTR (subject, "C=NO,ST=Oslo,L=Oslo,O=MongoDB,OU=Drivers,CN=client");
bson_free (subject);
}
#endif
void
test_x509_install (TestSuite *suite)
{
#ifdef MONGOC_ENABLE_OPENSSL
TestSuite_Add (suite, "/X509/extract_subject", test_extract_subject);
#endif
}
|
e3da80c8c57eaba6074c0543f5576e178eeffecb | vim/startup/functions/directories.vim | vim/startup/functions/directories.vim | function! Cdfile()
cd %:h
pwd
endfunction
" cd to the root of the current file's git directory
function! Cdroot()
cd %:h
exec "cd " . Trim(system("git rev-parse --show-toplevel"))
pwd
endfunction
| function! Cdfile()
if expand('%') != ''
cd %:h
else
echom "Not currently in a file."
endif
endfunction
" cd to the root of the current file's git directory
function! Cdroot()
call Cdfile()
exec "cd " . Trim(system("git rev-parse --show-toplevel"))
echom expand('.')
endfunction
| Make Cdf and Cdr no-ops when not in a file | Make Cdf and Cdr no-ops when not in a file
| VimL | mit | yarko3/dotfiles,yarko3/dotfiles | viml | ## Code Before:
function! Cdfile()
cd %:h
pwd
endfunction
" cd to the root of the current file's git directory
function! Cdroot()
cd %:h
exec "cd " . Trim(system("git rev-parse --show-toplevel"))
pwd
endfunction
## Instruction:
Make Cdf and Cdr no-ops when not in a file
## Code After:
function! Cdfile()
if expand('%') != ''
cd %:h
else
echom "Not currently in a file."
endif
endfunction
" cd to the root of the current file's git directory
function! Cdroot()
call Cdfile()
exec "cd " . Trim(system("git rev-parse --show-toplevel"))
echom expand('.')
endfunction
|
74482eab5bfb8d756e43293be90379e149e5c11b | README.md | README.md | **go-metrics-prometheus**
[![Build Status](https://api.travis-ci.org/deathowl/go-metrics-prometheus.svg)](https://travis-ci.org/deathowl/go-metrics-prometheus)
This is a reporter for the go-metrics library which will post the metrics to the prometheus client registry . It just updates the registry, taking care of exporting the metrics is still your responsibility.
Usage:
```
import "github.com/deathowl/go-metrics-prometheus"
import "github.com/prometheus/client_golang/prometheus"
prometheusRegistry := prometheus.NewRegistry()
metricsRegistry := metrics.NewRegistry()
pClient := NewPrometheusProvider(metricsRegistry, "test", "subsys", prometheusRegistry, 1*time.Second)
go pClient.UpdatePrometheusMetrics()
```
| **go-metrics-prometheus**
[![Build Status](https://api.travis-ci.org/deathowl/go-metrics-prometheus.svg)](https://travis-ci.org/deathowl/go-metrics-prometheus)
This is a reporter for the go-metrics library which will post the metrics to the prometheus client registry . It just updates the registry, taking care of exporting the metrics is still your responsibility.
Usage:
```
import "github.com/deathowl/go-metrics-prometheus"
import "github.com/prometheus/client_golang/prometheus"
metricsRegistry := metrics.NewRegistry()
prometheusClient := prometheusmetrics.NewPrometheusProvider(
metrics.DefaultRegistry, "whatever","something",prometheus.DefaultRegisterer, 1*time.Second)
go prometheusClient.UpdatePrometheusMetrics()
```
| Add info about using DefaultRegisterer to readme | Add info about using DefaultRegisterer to readme
Add info about using prometheus.DefaultRegisterer instead of prometheus.NewRegistry() | Markdown | apache-2.0 | deathowl/go-metrics-prometheus,deathowl/go-metrics-prometheus | markdown | ## Code Before:
**go-metrics-prometheus**
[![Build Status](https://api.travis-ci.org/deathowl/go-metrics-prometheus.svg)](https://travis-ci.org/deathowl/go-metrics-prometheus)
This is a reporter for the go-metrics library which will post the metrics to the prometheus client registry . It just updates the registry, taking care of exporting the metrics is still your responsibility.
Usage:
```
import "github.com/deathowl/go-metrics-prometheus"
import "github.com/prometheus/client_golang/prometheus"
prometheusRegistry := prometheus.NewRegistry()
metricsRegistry := metrics.NewRegistry()
pClient := NewPrometheusProvider(metricsRegistry, "test", "subsys", prometheusRegistry, 1*time.Second)
go pClient.UpdatePrometheusMetrics()
```
## Instruction:
Add info about using DefaultRegisterer to readme
Add info about using prometheus.DefaultRegisterer instead of prometheus.NewRegistry()
## Code After:
**go-metrics-prometheus**
[![Build Status](https://api.travis-ci.org/deathowl/go-metrics-prometheus.svg)](https://travis-ci.org/deathowl/go-metrics-prometheus)
This is a reporter for the go-metrics library which will post the metrics to the prometheus client registry . It just updates the registry, taking care of exporting the metrics is still your responsibility.
Usage:
```
import "github.com/deathowl/go-metrics-prometheus"
import "github.com/prometheus/client_golang/prometheus"
metricsRegistry := metrics.NewRegistry()
prometheusClient := prometheusmetrics.NewPrometheusProvider(
metrics.DefaultRegistry, "whatever","something",prometheus.DefaultRegisterer, 1*time.Second)
go prometheusClient.UpdatePrometheusMetrics()
```
|
a83e9866b5aad2cba207f450f373bfdb6e59ce44 | README.md | README.md |
U radu će biti opisane osnove BPMN 2.0, te osnovne mogućnosti HTML Canvas elementa. Praktični dio rada obuhvaćati će Web aplikaciju za crtanje modela procesa, realizirana pomoću HTML 5 Canvas tehnologije. Aplikacija će također omogućavati analiziranje modela kroz tablični prikaz procesa i povezanih klasa.
## Sadržaj
1. [Uvod](## Uvod)
1. [Modeliranje procesa](## Modeliranje procesa)
1. [Povijest](### Povijest)
1. [Standardi](### Standardi)
1. [OMG](### OMG)
## Uvod
## Modeliranje procesa
### Povijest
### Standardi
### OMG
## Resursi
[HTML 5 Canvas YouTube tutorial](https://www.youtube.com/watch?v=EO6OkltgudE&list=PLpPnRKq7eNW3We9VdCfx9fprhqXHwTPXL)
[PaperJS Docs](http://paperjs.org/reference/global/#)
[PaperJS Tuts](http://paperjs.org/tutorials/)
|
U radu će biti opisane osnove BPMN 2.0, te osnovne mogućnosti HTML Canvas elementa. Praktični dio rada obuhvaćati će Web aplikaciju za crtanje modela procesa, realizirana pomoću HTML 5 Canvas tehnologije. Aplikacija će također omogućavati analiziranje modela kroz tablični prikaz procesa i povezanih klasa.
## Resursi
[HTML 5 Canvas YouTube tutorial](https://www.youtube.com/watch?v=EO6OkltgudE&list=PLpPnRKq7eNW3We9VdCfx9fprhqXHwTPXL)
[PaperJS Docs](http://paperjs.org/reference/global/#)
[PaperJS Tuts](http://paperjs.org/tutorials/)
| Update Readme - removed table of contents | Update Readme - removed table of contents | Markdown | mit | gloga/bpmn-canvas-app,gloga/bpmn-canvas-app | markdown | ## Code Before:
U radu će biti opisane osnove BPMN 2.0, te osnovne mogućnosti HTML Canvas elementa. Praktični dio rada obuhvaćati će Web aplikaciju za crtanje modela procesa, realizirana pomoću HTML 5 Canvas tehnologije. Aplikacija će također omogućavati analiziranje modela kroz tablični prikaz procesa i povezanih klasa.
## Sadržaj
1. [Uvod](## Uvod)
1. [Modeliranje procesa](## Modeliranje procesa)
1. [Povijest](### Povijest)
1. [Standardi](### Standardi)
1. [OMG](### OMG)
## Uvod
## Modeliranje procesa
### Povijest
### Standardi
### OMG
## Resursi
[HTML 5 Canvas YouTube tutorial](https://www.youtube.com/watch?v=EO6OkltgudE&list=PLpPnRKq7eNW3We9VdCfx9fprhqXHwTPXL)
[PaperJS Docs](http://paperjs.org/reference/global/#)
[PaperJS Tuts](http://paperjs.org/tutorials/)
## Instruction:
Update Readme - removed table of contents
## Code After:
U radu će biti opisane osnove BPMN 2.0, te osnovne mogućnosti HTML Canvas elementa. Praktični dio rada obuhvaćati će Web aplikaciju za crtanje modela procesa, realizirana pomoću HTML 5 Canvas tehnologije. Aplikacija će također omogućavati analiziranje modela kroz tablični prikaz procesa i povezanih klasa.
## Resursi
[HTML 5 Canvas YouTube tutorial](https://www.youtube.com/watch?v=EO6OkltgudE&list=PLpPnRKq7eNW3We9VdCfx9fprhqXHwTPXL)
[PaperJS Docs](http://paperjs.org/reference/global/#)
[PaperJS Tuts](http://paperjs.org/tutorials/)
|
afdfcef3cf7f390dd0fc7eac0806272742ffa479 | core/models/payment.py | core/models/payment.py | from django.db import models
from django.db.models import signals
from django.utils.translation import ugettext_lazy as _
from core.mixins import AuditableMixin
from .invoice import Invoice
class Payment(AuditableMixin, models.Model):
invoice = models.ForeignKey(
Invoice, editable=False, on_delete=models.CASCADE,
verbose_name=_("Invoice")
)
description = models.TextField(
blank=True, null=True, verbose_name=_("Description")
)
total = models.DecimalField(
max_digits=12, decimal_places=2, verbose_name=_("Total")
)
class Meta:
ordering = ['-date_creation', ]
verbose_name = _("Payment")
verbose_name_plural = _("Payments")
def __str__(self):
return "%.2f" % self.total
def get_absolute_url(self):
return self.parent.get_absolute_url()
@property
def company(self):
return self.parent.company
@property
def parent(self):
return self.invoice
def post_save_payment(instance, sender, created, **kwargs):
if instance.invoice.is_payed and not instance.company.is_active:
instance.company.activate()
signals.post_save.connect(post_save_payment, sender=Payment)
| from django.db import models
from django.db.models import signals
from django.utils.translation import ugettext_lazy as _
from core.mixins import AuditableMixin
class Payment(AuditableMixin, models.Model):
invoice = models.ForeignKey(
'core.Invoice', editable=False, on_delete=models.CASCADE,
verbose_name=_("Invoice")
)
description = models.TextField(
blank=True, null=True, verbose_name=_("Description")
)
total = models.DecimalField(
max_digits=12, decimal_places=2, verbose_name=_("Total")
)
class Meta:
ordering = ['-date_creation', ]
verbose_name = _("Payment")
verbose_name_plural = _("Payments")
def __str__(self):
return "%.2f" % self.total
def get_absolute_url(self):
return self.parent.get_absolute_url()
@property
def company(self):
return self.parent.company
@property
def parent(self):
return self.invoice
def post_save_payment(instance, sender, created, **kwargs):
if instance.invoice.is_paid and not instance.company.is_active:
instance.company.activate()
signals.post_save.connect(post_save_payment, sender=Payment)
| Use string instead of class | Use string instead of class
| Python | bsd-3-clause | ikcam/django-skeleton,ikcam/django-skeleton,ikcam/django-skeleton,ikcam/django-skeleton | python | ## Code Before:
from django.db import models
from django.db.models import signals
from django.utils.translation import ugettext_lazy as _
from core.mixins import AuditableMixin
from .invoice import Invoice
class Payment(AuditableMixin, models.Model):
invoice = models.ForeignKey(
Invoice, editable=False, on_delete=models.CASCADE,
verbose_name=_("Invoice")
)
description = models.TextField(
blank=True, null=True, verbose_name=_("Description")
)
total = models.DecimalField(
max_digits=12, decimal_places=2, verbose_name=_("Total")
)
class Meta:
ordering = ['-date_creation', ]
verbose_name = _("Payment")
verbose_name_plural = _("Payments")
def __str__(self):
return "%.2f" % self.total
def get_absolute_url(self):
return self.parent.get_absolute_url()
@property
def company(self):
return self.parent.company
@property
def parent(self):
return self.invoice
def post_save_payment(instance, sender, created, **kwargs):
if instance.invoice.is_payed and not instance.company.is_active:
instance.company.activate()
signals.post_save.connect(post_save_payment, sender=Payment)
## Instruction:
Use string instead of class
## Code After:
from django.db import models
from django.db.models import signals
from django.utils.translation import ugettext_lazy as _
from core.mixins import AuditableMixin
class Payment(AuditableMixin, models.Model):
invoice = models.ForeignKey(
'core.Invoice', editable=False, on_delete=models.CASCADE,
verbose_name=_("Invoice")
)
description = models.TextField(
blank=True, null=True, verbose_name=_("Description")
)
total = models.DecimalField(
max_digits=12, decimal_places=2, verbose_name=_("Total")
)
class Meta:
ordering = ['-date_creation', ]
verbose_name = _("Payment")
verbose_name_plural = _("Payments")
def __str__(self):
return "%.2f" % self.total
def get_absolute_url(self):
return self.parent.get_absolute_url()
@property
def company(self):
return self.parent.company
@property
def parent(self):
return self.invoice
def post_save_payment(instance, sender, created, **kwargs):
if instance.invoice.is_paid and not instance.company.is_active:
instance.company.activate()
signals.post_save.connect(post_save_payment, sender=Payment)
|
a8857834ca63ead1d53c7136ada3f27d77bc7a99 | src/store.js | src/store.js | //@flow
import { createStore, compose, applyMiddleware } from "redux";
import { routerMiddleware } from "react-router-redux";
import createHistory from "history/createBrowserHistory";
import reducers from "./data/reducers";
const defaultState = {};
export const history = createHistory();
const middlewares = [routerMiddleware(history)];
if (process.env.NODE_ENV === `development`) {
const { logger } = require(`redux-logger`);
middlewares.push(logger);
}
const enhancers = compose(
window.devToolsExtension ? window.devToolsExtension() : f => f,
applyMiddleware(...middlewares)
);
const store = createStore(reducers, defaultState, enhancers);
export default function configureStore() {
const store = createStore(reducers, defaultState, enhancers);
if (module.hot) {
module.hot.accept(reducers, () => {
const nextRootReducer = require("./data/reducers").default;
store.replaceReducer(nextRootReducer);
});
}
}
| //@flow
import { createStore, compose, applyMiddleware } from "redux";
import { routerMiddleware } from "react-router-redux";
import createHistory from "history/createBrowserHistory";
import reducers from "./data/reducers";
import cards from "./data/state/cards";
const defaultState = { cards };
export const history = createHistory();
const middlewares = [routerMiddleware(history)];
if (process.env.NODE_ENV === `development`) {
const { logger } = require(`redux-logger`);
middlewares.push(logger);
}
const enhancers = compose(
window.devToolsExtension ? window.devToolsExtension() : f => f,
applyMiddleware(...middlewares)
);
const store = createStore(reducers, defaultState, enhancers);
if (module.hot) {
module.hot.accept("./data/reducers", () => {
store.replaceReducer(reducers);
});
}
export default store;
| Add cards to default state and hot reload reducers | Add cards to default state and hot reload reducers
| JavaScript | mit | slightly-askew/portfolio-2017,slightly-askew/portfolio-2017 | javascript | ## Code Before:
//@flow
import { createStore, compose, applyMiddleware } from "redux";
import { routerMiddleware } from "react-router-redux";
import createHistory from "history/createBrowserHistory";
import reducers from "./data/reducers";
const defaultState = {};
export const history = createHistory();
const middlewares = [routerMiddleware(history)];
if (process.env.NODE_ENV === `development`) {
const { logger } = require(`redux-logger`);
middlewares.push(logger);
}
const enhancers = compose(
window.devToolsExtension ? window.devToolsExtension() : f => f,
applyMiddleware(...middlewares)
);
const store = createStore(reducers, defaultState, enhancers);
export default function configureStore() {
const store = createStore(reducers, defaultState, enhancers);
if (module.hot) {
module.hot.accept(reducers, () => {
const nextRootReducer = require("./data/reducers").default;
store.replaceReducer(nextRootReducer);
});
}
}
## Instruction:
Add cards to default state and hot reload reducers
## Code After:
//@flow
import { createStore, compose, applyMiddleware } from "redux";
import { routerMiddleware } from "react-router-redux";
import createHistory from "history/createBrowserHistory";
import reducers from "./data/reducers";
import cards from "./data/state/cards";
const defaultState = { cards };
export const history = createHistory();
const middlewares = [routerMiddleware(history)];
if (process.env.NODE_ENV === `development`) {
const { logger } = require(`redux-logger`);
middlewares.push(logger);
}
const enhancers = compose(
window.devToolsExtension ? window.devToolsExtension() : f => f,
applyMiddleware(...middlewares)
);
const store = createStore(reducers, defaultState, enhancers);
if (module.hot) {
module.hot.accept("./data/reducers", () => {
store.replaceReducer(reducers);
});
}
export default store;
|
12ea2e331e23eb4e8d05b14b81d67d01d5a87b28 | .github/workflows/release.yml | .github/workflows/release.yml | name: tag
on:
push:
tags:
# this is a glob, not a regexp
- '[0-9]*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Build release tarball
# run as root; current Ubuntu podman breaks user networking ("could not find slirp4netns")
run: sudo PUBLISH_TAR=1 tests/run-apt
- name: Create GitHub release
uses: docker://antonyurchenko/git-release:latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHANGELOG_FILE: "NEWS"
with:
args: umockdev-*.tar.xz
| name: tag
on:
push:
tags:
# this is a glob, not a regexp
- '[0-9]*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Workaround for https://github.com/actions/checkout/pull/697
run: git fetch --force origin $(git describe --tags):refs/tags/$(git describe --tags)
- name: Build release tarball
# run as root; current Ubuntu podman breaks user networking ("could not find slirp4netns")
run: sudo PUBLISH_TAR=1 tests/run-apt
- name: Create GitHub release
uses: docker://antonyurchenko/git-release:latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHANGELOG_FILE: "NEWS"
with:
args: umockdev-*.tar.xz
| Add workaround for actions/checkout tag breakage | workflows: Add workaround for actions/checkout tag breakage
See https://github.com/actions/checkout/pull/697
| YAML | lgpl-2.1 | martinpitt/umockdev,martinpitt/umockdev,martinpitt/umockdev | yaml | ## Code Before:
name: tag
on:
push:
tags:
# this is a glob, not a regexp
- '[0-9]*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Build release tarball
# run as root; current Ubuntu podman breaks user networking ("could not find slirp4netns")
run: sudo PUBLISH_TAR=1 tests/run-apt
- name: Create GitHub release
uses: docker://antonyurchenko/git-release:latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHANGELOG_FILE: "NEWS"
with:
args: umockdev-*.tar.xz
## Instruction:
workflows: Add workaround for actions/checkout tag breakage
See https://github.com/actions/checkout/pull/697
## Code After:
name: tag
on:
push:
tags:
# this is a glob, not a regexp
- '[0-9]*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Workaround for https://github.com/actions/checkout/pull/697
run: git fetch --force origin $(git describe --tags):refs/tags/$(git describe --tags)
- name: Build release tarball
# run as root; current Ubuntu podman breaks user networking ("could not find slirp4netns")
run: sudo PUBLISH_TAR=1 tests/run-apt
- name: Create GitHub release
uses: docker://antonyurchenko/git-release:latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHANGELOG_FILE: "NEWS"
with:
args: umockdev-*.tar.xz
|
Multilingual version of https://huggingface.co/datasets/nuprl/EditPackFT
If you use our work, please cite our paper as such:
@misc{cassano2023edit,
title={Can It Edit? Evaluating the Ability of Large Language Models to Follow Code Editing Instructions},
author={Federico Cassano and Luisa Li and Akul Sethi and Noah Shinn and Abby Brennan-Jones and Anton Lozhkov and Carolyn Jane Anderson and Arjun Guha},
year={2023},
eprint={2312.12450},
archivePrefix={arXiv},
primaryClass={cs.SE}
}