commit stringlengths 40 40 | old_file stringlengths 4 184 | new_file stringlengths 4 184 | old_contents stringlengths 1 3.6k | new_contents stringlengths 5 3.38k | subject stringlengths 15 778 | message stringlengths 16 6.74k | lang stringclasses 201
values | license stringclasses 13
values | repos stringlengths 6 116k | config stringclasses 201
values | content stringlengths 137 7.24k | diff stringlengths 26 5.55k | diff_length int64 1 123 | relative_diff_length float64 0.01 89 | n_lines_added int64 0 108 | n_lines_deleted int64 0 106 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
26fa72b9a0dfafa7f12f7f6d2c4070c51be8d175 | package.json | package.json | {
"name": "botimize-botkit-middleware",
"version": "0.0.1",
"description": "The botimize middleware of botkit",
"directories": {
"lib": "./lib"
},
"keywords": [
"botimize",
"botkit",
"middleware"
],
"author": "botimize, Inc. <dev@botimize.io>",
"license": "MIT",
"repository": {
"... | {
"name": "botimize-botkit-middleware",
"version": "0.0.1",
"description": "The botimize middleware of botkit",
"directories": {
"lib": "./lib"
},
"keywords": [
"botimize",
"botkit",
"middleware"
],
"author": "botimize, Inc. <dev@botimize.io>",
"license": "MIT",
"repository": {
"... | Add botimize as peer dependency | Add botimize as peer dependency
| JSON | mit | botimize/botimize-botkit-middleware | json | ## Code Before:
{
"name": "botimize-botkit-middleware",
"version": "0.0.1",
"description": "The botimize middleware of botkit",
"directories": {
"lib": "./lib"
},
"keywords": [
"botimize",
"botkit",
"middleware"
],
"author": "botimize, Inc. <dev@botimize.io>",
"license": "MIT",
"repo... | {
"name": "botimize-botkit-middleware",
"version": "0.0.1",
"description": "The botimize middleware of botkit",
"directories": {
"lib": "./lib"
},
"keywords": [
"botimize",
"botkit",
"middleware"
],
"author": "botimize, Inc. <dev@botimize.io>",
"license": "M... | 7 | 0.21875 | 6 | 1 |
6f666a8eb6e3a0f0c6909a6631eb8b3abc14d964 | config/final.yml | config/final.yml | ---
final_name: bosh-google-cpi
blobstore:
provider: s3
options:
bucket_name: bosh-cpi-artifacts
host: storage.googleapis.com
| ---
final_name: bosh-google-cpi
blobstore:
provider: s3
options:
bucket: bosh-cpi-artifacts
bucket_name: bosh-cpi-artifacts
host: storage.googleapis.com
endpoint: https://storage.googleapis.com
| Support GCS blobstore client for un-authenticated use | config: Support GCS blobstore client for un-authenticated use
| YAML | apache-2.0 | cloudfoundry-incubator/bosh-google-cpi-release,evandbrown/bosh-google-cpi-release,cloudfoundry-incubator/bosh-google-cpi-release,erjohnso/bosh-google-cpi-release,evandbrown/bosh-google-cpi-release,erjohnso/bosh-google-cpi-release,evandbrown/bosh-google-cpi-release,cloudfoundry-incubator/bosh-google-cpi-release,evandbro... | yaml | ## Code Before:
---
final_name: bosh-google-cpi
blobstore:
provider: s3
options:
bucket_name: bosh-cpi-artifacts
host: storage.googleapis.com
## Instruction:
config: Support GCS blobstore client for un-authenticated use
## Code After:
---
final_name: bosh-google-cpi
blobstore:
provider: s3
options:
... | ---
final_name: bosh-google-cpi
blobstore:
provider: s3
options:
+ bucket: bosh-cpi-artifacts
bucket_name: bosh-cpi-artifacts
host: storage.googleapis.com
+ endpoint: https://storage.googleapis.com | 2 | 0.285714 | 2 | 0 |
93b285cf8b90d2e208893e39b0f9e62786ecefc4 | controllers/qpv.js | controllers/qpv.js | var express = require('express')
, router = express.Router()
, Qpv = require('../models/qpv.js')
, geojson = require('../helpers/geojson.js')
, isvalidgeo = require('../helpers/isvalidgeo')
, turf = require('turf')
router.get('/layer', function(req, res) {
if (req.query.bbox){
var bbox = req.query.bbox... | var express = require('express')
, router = express.Router()
, Qpv = require('../models/qpv.js')
, geojson = require('../helpers/geojson.js')
, isvalidgeo = require('../helpers/isvalidgeo')
, turf = require('turf')
router.get('/layer', function(req, res) {
if (req.query.bbox){
var bbox = req.query.bbox... | Fix typo with the usage of req.query | Fix typo with the usage of req.query
| JavaScript | mit | blackrez/apicarto-qpv,blackrez/apicarto-qpv | javascript | ## Code Before:
var express = require('express')
, router = express.Router()
, Qpv = require('../models/qpv.js')
, geojson = require('../helpers/geojson.js')
, isvalidgeo = require('../helpers/isvalidgeo')
, turf = require('turf')
router.get('/layer', function(req, res) {
if (req.query.bbox){
var bbox ... | var express = require('express')
, router = express.Router()
, Qpv = require('../models/qpv.js')
, geojson = require('../helpers/geojson.js')
, isvalidgeo = require('../helpers/isvalidgeo')
, turf = require('turf')
router.get('/layer', function(req, res) {
if (req.query.bbox){
var b... | 4 | 0.117647 | 2 | 2 |
c2952e753452b083daef6ef25ea82185fd2ba7ec | .travis.yml | .travis.yml | language: python
python:
- "2.7"
cache: pip
install:
- pip install -r requirements.txt -r test-requirements.txt
- pip install coveralls
# command to run tests
script:
- PYTHONPATH=${PYTHONPATH}:. py.test --cov gameserver gameserver/tests.py gameserver/wallet.py gameserver/wallet_sqlalchemy.py
notifications:
- sl... | language: python
python:
- "2.7"
cache: pip
install:
- pip install -U setuptools
- pip install -r requirements.txt -r test-requirements.txt
- pip install coveralls
# command to run tests
script:
- PYTHONPATH=${PYTHONPATH}:. py.test --cov gameserver gameserver/tests.py gameserver/wallet.py gameserver/wallet_sqlal... | Upgrade setuptools first before building; | Upgrade setuptools first before building;
| YAML | apache-2.0 | hammertoe/didactic-spork,hammertoe/didactic-spork,hammertoe/didactic-spork,hammertoe/didactic-spork | yaml | ## Code Before:
language: python
python:
- "2.7"
cache: pip
install:
- pip install -r requirements.txt -r test-requirements.txt
- pip install coveralls
# command to run tests
script:
- PYTHONPATH=${PYTHONPATH}:. py.test --cov gameserver gameserver/tests.py gameserver/wallet.py gameserver/wallet_sqlalchemy.py
noti... | language: python
python:
- "2.7"
cache: pip
install:
+ - pip install -U setuptools
- pip install -r requirements.txt -r test-requirements.txt
- pip install coveralls
# command to run tests
script:
- PYTHONPATH=${PYTHONPATH}:. py.test --cov gameserver gameserver/tests.py gameserver/wallet.py g... | 1 | 0.071429 | 1 | 0 |
16f6e1122790113949b6a4fef9199a45099ecdbe | lib/middlewares/override_welcome_action.rb | lib/middlewares/override_welcome_action.rb |
class OverrideWelcomeAction
def initialize(app)
@app = app
end
def call(env)
# Load gobierto_site, used by route constraints
full_domain = (env["HTTP_HOST"] || env["SERVER_NAME"] || env["SERVER_ADDR"]).split(":").first
if site = Site.find_by_allowed_domain(full_domain)
env["gobierto_site"... |
class OverrideWelcomeAction
def initialize(app)
@app = app
end
def call(env)
# Load gobierto_site, used by route constraints
full_domain = (env["HTTP_HOST"] || env["SERVER_NAME"] || env["SERVER_ADDR"]).split(":").first
if site = Site.find_by_allowed_domain(full_domain)
env["gobierto_site"... | Set site default locale when module is GobiertoPeople in override welcome action for / path | Set site default locale when module is GobiertoPeople in override welcome action for / path
| Ruby | agpl-3.0 | PopulateTools/gobierto,PopulateTools/gobierto-dev,PopulateTools/gobierto,PopulateTools/gobierto,PopulateTools/gobierto-dev,PopulateTools/gobierto-dev,PopulateTools/gobierto,PopulateTools/gobierto-dev | ruby | ## Code Before:
class OverrideWelcomeAction
def initialize(app)
@app = app
end
def call(env)
# Load gobierto_site, used by route constraints
full_domain = (env["HTTP_HOST"] || env["SERVER_NAME"] || env["SERVER_ADDR"]).split(":").first
if site = Site.find_by_allowed_domain(full_domain)
env... |
class OverrideWelcomeAction
def initialize(app)
@app = app
end
def call(env)
# Load gobierto_site, used by route constraints
full_domain = (env["HTTP_HOST"] || env["SERVER_NAME"] || env["SERVER_ADDR"]).split(":").first
if site = Site.find_by_allowed_domain(full_domain)
... | 6 | 0.2 | 5 | 1 |
219c1ee272979e78c3fcf381e9000cadeb43c31f | appveyor.yml | appveyor.yml | version: 1.0.{build}
environment:
EveTestServer: http://evenet-testbed.herokuapp.com/
before_build:
- cmd: nuget restore
build:
verbosity: minimal
artifacts:
- path: '.nupkg\**\*.nupkg'
deploy:
provider: NuGet
api_key:
secure: n79bIyukFqGL7AjtPzsYj/4BNjkyvmT7s2lsUIxjgG0R3VB2K7jJBjE6zltrUEJT
skip_symbols... | version: 1.0.{build}
image: Visual Studio 2017
environment:
EveTestServer: http://evenet-testbed.herokuapp.com/
before_build:
- cmd: nuget restore
build:
verbosity: minimal
artifacts:
- path: '.nupkg\**\*.nupkg'
deploy:
provider: NuGet
api_key:
secure: n79bIyukFqGL7AjtPzsYj/4BNjkyvmT7s2lsUIxjgG0R3VB2K7jJB... | Use VS2017 image on AppVeyor CI | Use VS2017 image on AppVeyor CI
| YAML | bsd-3-clause | nicolaiarocci/Eve.NET | yaml | ## Code Before:
version: 1.0.{build}
environment:
EveTestServer: http://evenet-testbed.herokuapp.com/
before_build:
- cmd: nuget restore
build:
verbosity: minimal
artifacts:
- path: '.nupkg\**\*.nupkg'
deploy:
provider: NuGet
api_key:
secure: n79bIyukFqGL7AjtPzsYj/4BNjkyvmT7s2lsUIxjgG0R3VB2K7jJBjE6zltrUEJ... | version: 1.0.{build}
+ image: Visual Studio 2017
environment:
EveTestServer: http://evenet-testbed.herokuapp.com/
before_build:
- cmd: nuget restore
build:
verbosity: minimal
artifacts:
- path: '.nupkg\**\*.nupkg'
deploy:
provider: NuGet
api_key:
secure: n79bIyukFqGL7AjtPzsYj/4BN... | 1 | 0.058824 | 1 | 0 |
5ed63aee1fe6838185114717a0f2c10a8a9ddedb | README.md | README.md |
By Matthias Noback
## Getting started
Clone this project:
git clone git@github.com:matthiasnoback/symfony-dependency-injection-workshop.git
cd symfony-dependency-injection-workshop
Install [Composer](https://getcomposer.org/download/) if you don't have it already.
Run:
composer install
Try:
php... |
By [Matthias Noback](http://php-and-symfony.matthiasnoback.nl/)
## Getting started
Clone this project:
git clone git@github.com:matthiasnoback/symfony-dependency-injection-workshop.git
cd symfony-dependency-injection-workshop
Install [Composer](https://getcomposer.org/download/) if you don't have it alread... | Add a note about the tests | Add a note about the tests
| Markdown | mit | matthiasnoback/symfony-dependency-injection-workshop | markdown | ## Code Before:
By Matthias Noback
## Getting started
Clone this project:
git clone git@github.com:matthiasnoback/symfony-dependency-injection-workshop.git
cd symfony-dependency-injection-workshop
Install [Composer](https://getcomposer.org/download/) if you don't have it already.
Run:
composer instal... |
- By Matthias Noback
+ By [Matthias Noback](http://php-and-symfony.matthiasnoback.nl/)
## Getting started
Clone this project:
git clone git@github.com:matthiasnoback/symfony-dependency-injection-workshop.git
cd symfony-dependency-injection-workshop
Install [Composer](https://getcomposer... | 9 | 0.375 | 8 | 1 |
1eddf29307b02c2e877e77cf1fea4ba1066719fa | README.md | README.md | Pre-processed election results for California elections
## Code License
See the [LICENSE](LICENSE.md) file for license rights and limitations (MIT).
| [](https://github.com/openelections/openelections-data-ca/actions)
[]... | Add badge to indicate status of data tests. | Add badge to indicate status of data tests.
| Markdown | mit | openelections/openelections-data-ca,openelections/openelections-data-ca | markdown | ## Code Before:
Pre-processed election results for California elections
## Code License
See the [LICENSE](LICENSE.md) file for license rights and limitations (MIT).
## Instruction:
Add badge to indicate status of data tests.
## Code After:
[](https://github.com/openelections/openelections-data-ca/actions)
+ [
{
final PersonModel perso... | package org.realityforge.arez.integration;
import javax.annotation.Nonnull;
import org.realityforge.arez.Arez;
import org.realityforge.arez.annotations.ArezComponent;
import org.realityforge.arez.annotations.Observable;
import org.realityforge.guiceyloops.shared.ValueUtil;
import org.testng.annotations.Test;
import st... | Use an isolated model so it does not interfere with other integration tests | Use an isolated model so it does not interfere with other integration tests
| Java | apache-2.0 | realityforge/arez,realityforge/arez,realityforge/arez | java | ## Code Before:
package org.realityforge.arez.integration;
import org.realityforge.arez.Arez;
import org.realityforge.guiceyloops.shared.ValueUtil;
import org.testng.annotations.Test;
import static org.testng.Assert.*;
public class EqualsAndHashCodeTest
{
@Test
public void equalsAndHashBasedOnId()
{
final P... | package org.realityforge.arez.integration;
+ import javax.annotation.Nonnull;
import org.realityforge.arez.Arez;
+ import org.realityforge.arez.annotations.ArezComponent;
+ import org.realityforge.arez.annotations.Observable;
import org.realityforge.guiceyloops.shared.ValueUtil;
import org.testng.annotations... | 41 | 1.518519 | 38 | 3 |
012d767d3099dd70c7c65df154dc189eb7ce85b8 | composer.json | composer.json | {
"authors": [
{
"name": "Edvinas Kručas",
"email": "edv.krucas@gmail.com"
}
],
"require-dev": {
"mockery/mockery": "0.9.*"
},
"autoload": {
"psr-0": {
"Krucas\\Permissions": "src/"
}
}
} | {
"authors": [
{
"name": "Edvinas Kručas",
"email": "edv.krucas@gmail.com"
}
],
"require-dev": {
"phpunit/phpunit": "4.3.*",
"mockery/mockery": "0.9.*"
},
"autoload": {
"psr-0": {
"Krucas\\Permissions": "src/"
}
... | Add phpunit as requirement for dev | Add phpunit as requirement for dev
| JSON | mit | edvinaskrucas/permission | json | ## Code Before:
{
"authors": [
{
"name": "Edvinas Kručas",
"email": "edv.krucas@gmail.com"
}
],
"require-dev": {
"mockery/mockery": "0.9.*"
},
"autoload": {
"psr-0": {
"Krucas\\Permissions": "src/"
}
}
}
## Instruction:
... | {
"authors": [
{
"name": "Edvinas Kručas",
"email": "edv.krucas@gmail.com"
}
],
"require-dev": {
+ "phpunit/phpunit": "4.3.*",
"mockery/mockery": "0.9.*"
},
"autoload": {
"psr-0": {
"Krucas\\Permiss... | 1 | 0.0625 | 1 | 0 |
463bb231149c75bbfdd7ad4b7c75cbbc77cff197 | ui/analyse/css/study/panel/_share.scss | ui/analyse/css/study/panel/_share.scss | .study__share {
@extend %box-neat;
background: $c-bg-box;
padding: 1.5em 1.2em;
input[type='text'] {
font-family: monospace;
width: 100%;
font-size: 0.9em;
}
.ply-wrap {
color: $c-font-dim;
text-align: left;
font-size: 0.9em;
}
.ply {
cursor: pointer;
input {
m... | .study__share {
@extend %box-neat;
background: $c-bg-box;
padding: 1.5em 1.2em;
input[type='text'] {
font-family: monospace;
width: 100%;
font-size: 0.9em;
}
.ply-wrap {
color: $c-font-dim;
text-align: left;
font-size: 0.9em;
}
.ply {
cursor: pointer;
input {
m... | Fix study share button wrapping | Fix study share button wrapping
| SCSS | agpl-3.0 | arex1337/lila,arex1337/lila,luanlv/lila,luanlv/lila,arex1337/lila,arex1337/lila,arex1337/lila,luanlv/lila,luanlv/lila,arex1337/lila,luanlv/lila,luanlv/lila,luanlv/lila,arex1337/lila | scss | ## Code Before:
.study__share {
@extend %box-neat;
background: $c-bg-box;
padding: 1.5em 1.2em;
input[type='text'] {
font-family: monospace;
width: 100%;
font-size: 0.9em;
}
.ply-wrap {
color: $c-font-dim;
text-align: left;
font-size: 0.9em;
}
.ply {
cursor: pointer;
... | .study__share {
@extend %box-neat;
background: $c-bg-box;
padding: 1.5em 1.2em;
input[type='text'] {
font-family: monospace;
width: 100%;
font-size: 0.9em;
}
.ply-wrap {
color: $c-font-dim;
text-align: left;
font-size: 0.9em;
}
.ply {
... | 9 | 0.272727 | 7 | 2 |
89b323667c9a869c21bc8c0b5bef5b128a970a5f | api-script-client/int_daily_build/run.sh | api-script-client/int_daily_build/run.sh | set -e; # Stop on error
# Declare run specific parameters
effectiveDate="2015-01-31"
readmeEndDate="2014"
isFirstTime=false
headless=true
extensionName="SNOMED CT International Edition"
dataLocation=$1
previousPublishedPackageName="SnomedCT_Release_INT_20140731.zip"
productName="SNOMED CT Release"
buildName="Int Daily... | set -e; # Stop on error
# Declare run specific parameters
effectiveDate="2015-01-31"
readmeEndDate="2014"
isFirstTime=false
headless=true
extensionName="SNOMED CT International Edition"
dataLocation=$1
previousPublishedPackageName="SnomedCT_Release_INT_20140731.zip"
productName="SNOMED CT Release"
buildName="Int Daily... | Package Name must match that being picked up by the daily comparison. | Package Name must match that being picked up by the daily comparison. | Shell | apache-2.0 | IHTSDO/snomed-release-service,IHTSDO/snomed-release-service | shell | ## Code Before:
set -e; # Stop on error
# Declare run specific parameters
effectiveDate="2015-01-31"
readmeEndDate="2014"
isFirstTime=false
headless=true
extensionName="SNOMED CT International Edition"
dataLocation=$1
previousPublishedPackageName="SnomedCT_Release_INT_20140731.zip"
productName="SNOMED CT Release"
buil... | set -e; # Stop on error
# Declare run specific parameters
effectiveDate="2015-01-31"
readmeEndDate="2014"
isFirstTime=false
headless=true
extensionName="SNOMED CT International Edition"
dataLocation=$1
previousPublishedPackageName="SnomedCT_Release_INT_20140731.zip"
productName="SNOMED CT Release... | 1 | 0.058824 | 1 | 0 |
dcccf28a67c44c4b864fbda6360b382a190f180f | src/components/Sidebar/index.js | src/components/Sidebar/index.js | import React from 'react';
import LazyLoad from 'react-lazyload';
import './index.scss';
const Sidebar = ({ post = false }) => (
<header className={`
intro-header
col-lg-2
col-xs-12
order-lg-1
${post === true ? 'order-md-10 order-10' : 'order-1'}
`}
>
<div className="site-heading text-... | import React from 'react';
import LazyLoad from 'react-lazyload';
import PropTypes from 'prop-types';
import './index.scss';
const Sidebar = ({ post }) => (
<header className={`intro-header col-lg-2 col-xs-12 order-lg-1 ${post === true ? 'order-md-10 order-10' : 'order-1'}`} >
<div className="site-heading text... | Fix sidebar classname multi-line problem | Fix sidebar classname multi-line problem
| JavaScript | mit | calpa/blog | javascript | ## Code Before:
import React from 'react';
import LazyLoad from 'react-lazyload';
import './index.scss';
const Sidebar = ({ post = false }) => (
<header className={`
intro-header
col-lg-2
col-xs-12
order-lg-1
${post === true ? 'order-md-10 order-10' : 'order-1'}
`}
>
<div className="si... | import React from 'react';
import LazyLoad from 'react-lazyload';
+ import PropTypes from 'prop-types';
+
import './index.scss';
- const Sidebar = ({ post = false }) => (
? --------
+ const Sidebar = ({ post }) => (
+ <header className={`intro-header col-lg-2 col-xs-12 order-lg-1... | 21 | 0.65625 | 12 | 9 |
fe8225bbfcb63e6db0ecd4227a61dde226a369b7 | applications/calendar/src/app/helpers/timezoneSuggestion.ts | applications/calendar/src/app/helpers/timezoneSuggestion.ts | import { SHA256, binaryStringToArray, arrayToHexString } from 'pmcrypto';
const DAY_IN_MILLISECONDS = 86400000;
const LOCALSTORAGE_TZ_KEY = 'tzSuggestion';
export const getTimezoneSuggestionKey = async (userID: string) => {
const value = await SHA256(binaryStringToArray(`${LOCALSTORAGE_TZ_KEY}${userID}`));
re... | import { getSHA256String } from 'proton-shared/lib/helpers/hash';
const DAY_IN_MILLISECONDS = 86400000;
const LOCALSTORAGE_TZ_KEY = 'tzSuggestion';
export const getTimezoneSuggestionKey = async (userID: string) => {
return getSHA256String(`${LOCALSTORAGE_TZ_KEY}${userID}`);
};
export const getLastTimezoneSuggest... | Use sha256 helper from proton-shared | Use sha256 helper from proton-shared
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | typescript | ## Code Before:
import { SHA256, binaryStringToArray, arrayToHexString } from 'pmcrypto';
const DAY_IN_MILLISECONDS = 86400000;
const LOCALSTORAGE_TZ_KEY = 'tzSuggestion';
export const getTimezoneSuggestionKey = async (userID: string) => {
const value = await SHA256(binaryStringToArray(`${LOCALSTORAGE_TZ_KEY}${us... | - import { SHA256, binaryStringToArray, arrayToHexString } from 'pmcrypto';
+ import { getSHA256String } from 'proton-shared/lib/helpers/hash';
const DAY_IN_MILLISECONDS = 86400000;
const LOCALSTORAGE_TZ_KEY = 'tzSuggestion';
export const getTimezoneSuggestionKey = async (userID: string) => {
+ return g... | 5 | 0.142857 | 2 | 3 |
2b73139732663f8099d993b558f05f9ae129564c | ci_environment/phpenv/attributes/default.rb | ci_environment/phpenv/attributes/default.rb | default[:phpenv] = {
:git => {
:repository => "git://github.com/CHH/phpenv.git",
:revision => "01a2c1e25096f8ff10f2f781428a5d470e1ecaba"
}
}
| default[:phpenv] = {
:git => {
:repository => "git://github.com/CHH/phpenv.git",
:revision => "44f89b8d124386d9920a2ae747caff288cf4d64c"
}
}
| Update "phpenv" to the latest commit | Update "phpenv" to the latest commit
| Ruby | mit | dracos/travis-cookbooks,dracos/travis-cookbooks,tianon/travis-cookbooks,Distelli/travis-cookbooks,Acidburn0zzz/travis-cookbooks,Zarthus/travis-cookbooks,Distelli/travis-cookbooks,ardock/travis-cookbooks,ardock/travis-cookbooks,gavioto/travis-cookbooks,travis-ci/travis-cookbooks,johanneswuerbach/travis-cookbooks,Distell... | ruby | ## Code Before:
default[:phpenv] = {
:git => {
:repository => "git://github.com/CHH/phpenv.git",
:revision => "01a2c1e25096f8ff10f2f781428a5d470e1ecaba"
}
}
## Instruction:
Update "phpenv" to the latest commit
## Code After:
default[:phpenv] = {
:git => {
:repository => "git://github.com/CHH/phpen... | default[:phpenv] = {
:git => {
:repository => "git://github.com/CHH/phpenv.git",
- :revision => "01a2c1e25096f8ff10f2f781428a5d470e1ecaba"
+ :revision => "44f89b8d124386d9920a2ae747caff288cf4d64c"
}
} | 2 | 0.333333 | 1 | 1 |
b4aaeaac7e5862dee254d72e063f3edf23e526a5 | spring-boot/src/main/java/org/springframework/boot/context/embedded/tomcat/TomcatEmbeddedContext.java | spring-boot/src/main/java/org/springframework/boot/context/embedded/tomcat/TomcatEmbeddedContext.java | /*
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by ap... | /*
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by ap... | Set Thread context class loader while Tomcat starts up | Set Thread context class loader while Tomcat starts up
Fixes gh-1085
| Java | apache-2.0 | imranansari/spring-boot,wwadge/spring-boot,Charkui/spring-boot,ydsakyclguozi/spring-boot,SaravananParthasarathy/SPSDemo,jxblum/spring-boot,tbbost/spring-boot,jayarampradhan/spring-boot,balajinsr/spring-boot,buobao/spring-boot,nebhale/spring-boot,ChunPIG/spring-boot,ractive/spring-boot,donhuvy/spring-boot,drumonii/sprin... | java | ## Code Before:
/*
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unles... | /*
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* U... | 14 | 0.368421 | 14 | 0 |
a8a92630bec0bfaaf78b56c674e854b852714213 | app/controllers/password-recovery.js | app/controllers/password-recovery.js | import { inject as service } from '@ember/service'
import Controller from '@ember/controller'
import { badRequest } from '../utils/request'
export default Controller.extend({
pilasBloquesApi: service(),
credentials: {},
usernameExists: true, // Default true for (no) error visualization
wrongCredentials: false,... | import { inject as service } from '@ember/service'
import Controller from '@ember/controller'
import { badRequest, notFound } from '../utils/request'
export default Controller.extend({
pilasBloquesApi: service(),
queryParams: ['token'],
token: null,
credentials: {},
usernameExists: true, // Default true for ... | Send token on change password | Send token on change password
| JavaScript | agpl-3.0 | Program-AR/pilas-bloques,Program-AR/pilas-bloques,Program-AR/pilas-bloques | javascript | ## Code Before:
import { inject as service } from '@ember/service'
import Controller from '@ember/controller'
import { badRequest } from '../utils/request'
export default Controller.extend({
pilasBloquesApi: service(),
credentials: {},
usernameExists: true, // Default true for (no) error visualization
wrongCre... | import { inject as service } from '@ember/service'
import Controller from '@ember/controller'
- import { badRequest } from '../utils/request'
+ import { badRequest, notFound } from '../utils/request'
? ++++++++++
export default Controller.extend({
pilasBloquesApi: service(),
+ queryPa... | 5 | 0.147059 | 4 | 1 |
91c3fd2dd629ffa8798f6b23b2984446a15f84b7 | tools/llvm-mca/CMakeLists.txt | tools/llvm-mca/CMakeLists.txt | set(LLVM_LINK_COMPONENTS
AllTargetsAsmPrinters
AllTargetsAsmParsers
AllTargetsDescs
AllTargetsDisassemblers
AllTargetsInfos
MC
MCParser
Support
)
add_llvm_tool(llvm-mca
Backend.cpp
BackendPrinter.cpp
CodeRegion.cpp
Dispatch.cpp
DispatchStatistics.cpp
HWEventListener.cpp
InstrBuilder.cpp... | set(LLVM_LINK_COMPONENTS
AllTargetsAsmParsers
AllTargetsDescs
)
add_llvm_tool(llvm-mca
Backend.cpp
BackendPrinter.cpp
CodeRegion.cpp
Dispatch.cpp
DispatchStatistics.cpp
HWEventListener.cpp
InstrBuilder.cpp
Instruction.cpp
InstructionInfoView.cpp
InstructionTables.cpp
LSUnit.cpp
llvm-mca.c... | Remove unused libraries from set LLVM_LINK_COMPONENTS. | [llvm-mca][CMake] Remove unused libraries from set LLVM_LINK_COMPONENTS.
git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@329807 91177308-0d34-0410-b5e6-96231b3b80d8
| Text | apache-2.0 | apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,apple/swift-llvm,GPUOpen-Drivers/llvm,llvm-mirror/llvm,llvm-mirror/llvm,llvm-mi... | text | ## Code Before:
set(LLVM_LINK_COMPONENTS
AllTargetsAsmPrinters
AllTargetsAsmParsers
AllTargetsDescs
AllTargetsDisassemblers
AllTargetsInfos
MC
MCParser
Support
)
add_llvm_tool(llvm-mca
Backend.cpp
BackendPrinter.cpp
CodeRegion.cpp
Dispatch.cpp
DispatchStatistics.cpp
HWEventListener.cpp
... | set(LLVM_LINK_COMPONENTS
- AllTargetsAsmPrinters
AllTargetsAsmParsers
AllTargetsDescs
- AllTargetsDisassemblers
- AllTargetsInfos
- MC
- MCParser
- Support
)
add_llvm_tool(llvm-mca
Backend.cpp
BackendPrinter.cpp
CodeRegion.cpp
Dispatch.cpp
DispatchStatistics.cpp
HW... | 6 | 0.176471 | 0 | 6 |
87f2ccd437ba6293806515c159ca438372776044 | _sass/queercode/components/events.scss | _sass/queercode/components/events.scss | .event-list {
display: flex;
flex-wrap: wrap;
}
.event-list > div {
margin-right: 1em;
min-width: 50ch;
}
| .event-list {
display: flex;
flex-wrap: wrap;
}
.event-list > div {
margin-right: 1em;
}
@media screen and (min-width: $tablet) {
min-width: 50ch;
}
| Fix event list rendering on mobile devices | Fix event list rendering on mobile devices
| SCSS | unlicense | QueerCodeOrg/queercodeberlin.github.io,QueerCodeOrg/queercodeberlin.github.io,QueerCodeBerlin/queercodeberlin.github.io,QueerCodeOrg/queercodeberlin.github.io | scss | ## Code Before:
.event-list {
display: flex;
flex-wrap: wrap;
}
.event-list > div {
margin-right: 1em;
min-width: 50ch;
}
## Instruction:
Fix event list rendering on mobile devices
## Code After:
.event-list {
display: flex;
flex-wrap: wrap;
}
.event-list > div {
margin-right: 1em;
}
@media screen an... | .event-list {
display: flex;
flex-wrap: wrap;
}
.event-list > div {
margin-right: 1em;
+ }
+
+ @media screen and (min-width: $tablet) {
min-width: 50ch;
} | 3 | 0.333333 | 3 | 0 |
6d601067a115d5bba2f8617584149b9a532a29ba | tests/Stub/SessionTestStub.php | tests/Stub/SessionTestStub.php | <?php
declare(strict_types=1);
namespace Tests\Stub;
use PHPUnit\Framework\TestCase;
class SessionTestStub extends TestCase
{
private const SESSION_ID = '42';
protected function setUp(): void
{
session_id(self::SESSION_ID);
}
public function testOne(): void
{
$process = new... | <?php
declare(strict_types=1);
namespace Tests\Stub;
use PHPUnit\Framework\TestCase;
class SessionTestStub extends TestCase
{
private const SESSION_ID = '42';
protected function setUp(): void
{
session_id(self::SESSION_ID);
}
public function testOne(): void
{
$process = new... | Fix arguments order in assertion | Fix arguments order in assertion
| PHP | apache-2.0 | facile-it/paraunit,facile-it/paraunit | php | ## Code Before:
<?php
declare(strict_types=1);
namespace Tests\Stub;
use PHPUnit\Framework\TestCase;
class SessionTestStub extends TestCase
{
private const SESSION_ID = '42';
protected function setUp(): void
{
session_id(self::SESSION_ID);
}
public function testOne(): void
{
... | <?php
declare(strict_types=1);
namespace Tests\Stub;
use PHPUnit\Framework\TestCase;
class SessionTestStub extends TestCase
{
private const SESSION_ID = '42';
protected function setUp(): void
{
session_id(self::SESSION_ID);
}
public function testOne(... | 2 | 0.058824 | 1 | 1 |
f9dc378cfd2db6b647c8b2500ece282ab65b69ac | index.js | index.js |
exports.express = function () {
return require('./lib/express')
}
exports.koa = function () {
return require('./lib/koa')
}
|
exports = module.exports = require('./lib/express')
exports.express = function () {
return require('./lib/express')
}
exports.koa = function () {
return require('./lib/koa')
}
| Load express implementation by default | Load express implementation by default
| JavaScript | mit | woltemade/grant,bitinn/grant,jlabarbera11/grant,woltemade/grant,jcdenton/grant,bitinn/grant,fejalish/grant,jcdenton/grant,simov/grant,fejalish/grant | javascript | ## Code Before:
exports.express = function () {
return require('./lib/express')
}
exports.koa = function () {
return require('./lib/koa')
}
## Instruction:
Load express implementation by default
## Code After:
exports = module.exports = require('./lib/express')
exports.express = function () {
return require... | +
+ exports = module.exports = require('./lib/express')
exports.express = function () {
return require('./lib/express')
}
exports.koa = function () {
return require('./lib/koa')
} | 2 | 0.25 | 2 | 0 |
9ddd1787bde526c89d90669ba4fb00c35f6a7cb4 | templates/html/mentoring_progress.html | templates/html/mentoring_progress.html | <script type="text/template" id="xblock-progress-template">
<% if (completed === "True") {{ %>
<img src="{completed}">
<% }} else {{ %>
(Not completed)
<% }} %>
</script>
| <script type="text/template" id="xblock-progress-template">
<% if (completed === "True") {{ %>
<img src="{completed}" alt="Completed">
<% }} else {{ %>
(Not completed)
<% }} %>
</script>
| Add `alt` to completion `<img>` for accessibility | html-css-review: Add `alt` to completion `<img>` for accessibility
| HTML | agpl-3.0 | proversity-org/problem-builder,open-craft/xblock-mentoring,open-craft/xblock-mentoring,proversity-org/problem-builder,gsehub/xblock-mentoring,open-craft/xblock-mentoring,gsehub/xblock-mentoring,proversity-org/problem-builder,edx-solutions/xblock-mentoring,edx-solutions/xblock-mentoring,edx-solutions/xblock-mentoring,gs... | html | ## Code Before:
<script type="text/template" id="xblock-progress-template">
<% if (completed === "True") {{ %>
<img src="{completed}">
<% }} else {{ %>
(Not completed)
<% }} %>
</script>
## Instruction:
html-css-review: Add `alt` to completion `<img>` for accessibility
## Code After:
<scri... | <script type="text/template" id="xblock-progress-template">
<% if (completed === "True") {{ %>
- <img src="{completed}">
+ <img src="{completed}" alt="Completed">
? ++++++++++++++++
<% }} else {{ %>
(Not completed)
<% }} %>
</script> | 2 | 0.285714 | 1 | 1 |
604c7d8889bc59dd53d2009fa12f576d40e3627f | .github/workflows/update.yml | .github/workflows/update.yml | name: update
on:
schedule:
- cron: '0 9 * * *'
jobs:
update:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: update
run: python3 generate.py >version.txt
- name: commit
run: git commit --author "GitHub <noreply@github.com>" -a -m "Update to 1.3.`cat ... | name: update
on:
schedule:
- cron: '0 9 * * *'
workflow_dispatch:
jobs:
update:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: update
run: python3 generate.py >version.txt
- name: commit
run: git commit --author "GitHub <noreply@github.com>" -a -m... | Allow to run the new workflow manually | Allow to run the new workflow manually
| YAML | mit | zeux/volk,zeux/volk,zeux/volk | yaml | ## Code Before:
name: update
on:
schedule:
- cron: '0 9 * * *'
jobs:
update:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: update
run: python3 generate.py >version.txt
- name: commit
run: git commit --author "GitHub <noreply@github.com>" -a -m "Upd... | name: update
on:
schedule:
- cron: '0 9 * * *'
+ workflow_dispatch:
jobs:
update:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: update
run: python3 generate.py >version.txt
- name: commit
run: git commit --author "Gi... | 1 | 0.055556 | 1 | 0 |
6ac23761f8b81107b967ea60ec7e9907947f167f | tox.ini | tox.ini | [tox]
envlist = py27, py33, py34, py35, py36, flake8
[testenv:flake8]
basepython=python
deps=flake8
commands=flake8 parglare
[testenv]
passenv = TRAVIS TRAVIS_JOB_ID TRAVIS_BRANCH
setenv =
PYTHONPATH = {toxinidir}:{toxinidir}/parglare
deps =
-r{toxinidir}/requirements_test.txt
commands =
coverage run --so... | [tox]
envlist = py27, py33, py34, py35, py36, flake8
[testenv:flake8]
basepython=python
deps=flake8
commands=flake8 parglare --exclude=six.py
[testenv]
passenv = TRAVIS TRAVIS_JOB_ID TRAVIS_BRANCH
setenv =
PYTHONPATH = {toxinidir}:{toxinidir}/parglare
deps =
-r{toxinidir}/requirements_test.txt
commands =
... | Exclude six.py from flake8 test. | Exclude six.py from flake8 test.
| INI | mit | igordejanovic/parglare,igordejanovic/parglare | ini | ## Code Before:
[tox]
envlist = py27, py33, py34, py35, py36, flake8
[testenv:flake8]
basepython=python
deps=flake8
commands=flake8 parglare
[testenv]
passenv = TRAVIS TRAVIS_JOB_ID TRAVIS_BRANCH
setenv =
PYTHONPATH = {toxinidir}:{toxinidir}/parglare
deps =
-r{toxinidir}/requirements_test.txt
commands =
c... | [tox]
envlist = py27, py33, py34, py35, py36, flake8
[testenv:flake8]
basepython=python
deps=flake8
- commands=flake8 parglare
+ commands=flake8 parglare --exclude=six.py
[testenv]
passenv = TRAVIS TRAVIS_JOB_ID TRAVIS_BRANCH
setenv =
PYTHONPATH = {toxinidir}:{toxinidir}/parglare
deps =
... | 2 | 0.117647 | 1 | 1 |
618d9c185a17d8b8e2a5b860e8c50ea1a7bde994 | .travis.yml | .travis.yml | language: php
php:
- 5.5
- 5.6
- hhvm-nightly
env:
- DB=mysql
matrix:
allow_failures:
- php: hhvm-nightly
before_script:
- composer --prefer-source --dev install
- cp phpunit.xml.dist phpunit.xml
- cp settings.default.php settings.php
- if [[ "$DB" == "mysql" ]]; then mysql -e "create database... | language: php
php:
- 5.5
- 5.6
- hhvm-nightly
env:
- DB=mysql
matrix:
allow_failures:
- php: hhvm-nightly
before_script:
- sudo apt-get install apache2
- sudo a2enmod rewrite
- sudo service apache2 restart
- ln -s ../dbmng2 /var/www/
- composer --prefer-source --dev install
- cp phpunit.xm... | Install apache and dbmng2 (for testing api) | Install apache and dbmng2 (for testing api)
| YAML | mit | diegoguidotti/dbmng2,diegoguidotti/dbmng2,diegoguidotti/dbmng2,diegoguidotti/dbmng2 | yaml | ## Code Before:
language: php
php:
- 5.5
- 5.6
- hhvm-nightly
env:
- DB=mysql
matrix:
allow_failures:
- php: hhvm-nightly
before_script:
- composer --prefer-source --dev install
- cp phpunit.xml.dist phpunit.xml
- cp settings.default.php settings.php
- if [[ "$DB" == "mysql" ]]; then mysql -e ... | language: php
php:
- 5.5
- 5.6
- hhvm-nightly
env:
- DB=mysql
matrix:
allow_failures:
- php: hhvm-nightly
before_script:
+ - sudo apt-get install apache2
+ - sudo a2enmod rewrite
+ - sudo service apache2 restart
+ - ln -s ../dbmng2 /var/www/
- composer --prefe... | 4 | 0.190476 | 4 | 0 |
4f1bd2889056dffb49f9dd45e1514fe99dff12c0 | lib/edit-command-line.zsh | lib/edit-command-line.zsh | autoload -U edit-command-line
zle -N edit-command-line
bindkey '\C-x\C-e' edit-command-line
| autoload -U edit-command-line
zle -N edit-command-line
bindkey '\C-x\C-e' edit-command-line
zmodload -i zsh/parameter
insert-last-command-output() {
LBUFFER+="$(eval $history[$((HISTCMD-1))])"
}
zle -N insert-last-command-output
bindkey '\C-x\C-i' insert-last-command-output
| Use Ctrl-x, Ctrl-i insert output of last command | Use Ctrl-x, Ctrl-i insert output of last command
| Shell | mit | toctan/oh-my-zsh,toctan/oh-my-zsh,toctan/oh-my-zsh | shell | ## Code Before:
autoload -U edit-command-line
zle -N edit-command-line
bindkey '\C-x\C-e' edit-command-line
## Instruction:
Use Ctrl-x, Ctrl-i insert output of last command
## Code After:
autoload -U edit-command-line
zle -N edit-command-line
bindkey '\C-x\C-e' edit-command-line
zmodload -i zsh/parameter
insert-last... | autoload -U edit-command-line
zle -N edit-command-line
bindkey '\C-x\C-e' edit-command-line
+
+ zmodload -i zsh/parameter
+ insert-last-command-output() {
+ LBUFFER+="$(eval $history[$((HISTCMD-1))])"
+ }
+ zle -N insert-last-command-output
+ bindkey '\C-x\C-i' insert-last-command-output | 7 | 2.333333 | 7 | 0 |
00352f3453eb0bb41d11c80b4a0666e91ad3092e | RuleDocumentation/UseConsistentIndentation.md | RuleDocumentation/UseConsistentIndentation.md |
**Severity Level: Warning**
## Description
Indentation should be consistent throughout the source file.
**Note**: This rule is not enabled by default. The user needs to enable it through settings.
## Configuration
```powershell
Rules = @{
PSUseConsistentIndentation = @{
Enable = $true
... |
**Severity Level: Warning**
## Description
Indentation should be consistent throughout the source file.
**Note**: This rule is not enabled by default. The user needs to enable it through settings.
## Configuration
```powershell
Rules = @{
PSUseConsistentIndentation = @{
Enable = $true
... | Add doc for Indentation.Kind parameter | Add doc for Indentation.Kind parameter
| Markdown | mit | PowerShell/PSScriptAnalyzer,dlwyatt/PSScriptAnalyzer,daviwil/PSScriptAnalyzer | markdown | ## Code Before:
**Severity Level: Warning**
## Description
Indentation should be consistent throughout the source file.
**Note**: This rule is not enabled by default. The user needs to enable it through settings.
## Configuration
```powershell
Rules = @{
PSUseConsistentIndentation = @{
Ena... |
**Severity Level: Warning**
## Description
Indentation should be consistent throughout the source file.
**Note**: This rule is not enabled by default. The user needs to enable it through settings.
## Configuration
```powershell
Rules = @{
PSUseConsistentIndentation = @{
... | 7 | 0.241379 | 7 | 0 |
a6300723150d7d1ff9a58f4f3f1297e0fe2c6f78 | css_updater/git/manager.py | css_updater/git/manager.py | """manages github repos"""
import os
import tempfile
from typing import Dict, Any
import pygit2 as git
from .webhook.handler import Handler
class Manager(object):
"""handles git repos"""
def __init__(self: Manager, handler: Handler) -> None:
self.webhook_handler: Handler = handler
self.temp... | """manages github repos"""
import os
import tempfile
from typing import Dict, Any
import pygit2 as git
from .webhook.handler import Handler
class Manager(object):
"""handles git repos"""
def __init__(self: Manager, handler: Handler) -> None:
self.webhook_handler: Handler = handler
self.temp... | Check for errors in config | Check for errors in config
| Python | mit | neoliberal/css-updater | python | ## Code Before:
"""manages github repos"""
import os
import tempfile
from typing import Dict, Any
import pygit2 as git
from .webhook.handler import Handler
class Manager(object):
"""handles git repos"""
def __init__(self: Manager, handler: Handler) -> None:
self.webhook_handler: Handler = handler
... | """manages github repos"""
import os
import tempfile
from typing import Dict, Any
import pygit2 as git
from .webhook.handler import Handler
class Manager(object):
"""handles git repos"""
def __init__(self: Manager, handler: Handler) -> None:
self.webhook_handler: Handl... | 7 | 0.28 | 6 | 1 |
ca871796f957f0ac147298ae67743507a2ea3ca1 | data/pests.txt | data/pests.txt | semalt\.com\/crawler\.php
semaltmedia\.com
buttons-for-website\.com
makemoneyonline\.com
buttons-for-your-website\.com
best-seo-offer\.com
100dollars-seo\.com
videos-for-your-business\.com
video--production\.com
justprofit\.xyz
phatvidz\.com
free-video-tool\.com
1-free-share-buttons\.com
| 1-free-share-buttons\.com
100dollars-seo\.com
best-seo-offer\.com
buttons-for-website\.com
buttons-for-your-website\.com
free-video-tool\.com
justprofit\.xyz
makemoneyonline\.com
phatvidz\.com
semalt\.com\/crawler\.php
semaltmedia\.com
video--production\.com
videos-for-your-business\.com
| Sort list of banned domains | Sort list of banned domains
| Text | mit | mdippery/rack-pesticide | text | ## Code Before:
semalt\.com\/crawler\.php
semaltmedia\.com
buttons-for-website\.com
makemoneyonline\.com
buttons-for-your-website\.com
best-seo-offer\.com
100dollars-seo\.com
videos-for-your-business\.com
video--production\.com
justprofit\.xyz
phatvidz\.com
free-video-tool\.com
1-free-share-buttons\.com
## Instruction... | + 1-free-share-buttons\.com
+ 100dollars-seo\.com
+ best-seo-offer\.com
+ buttons-for-website\.com
+ buttons-for-your-website\.com
+ free-video-tool\.com
+ justprofit\.xyz
+ makemoneyonline\.com
+ phatvidz\.com
semalt\.com\/crawler\.php
semaltmedia\.com
+ video--production\.com
- buttons-for-website\.com
- makemone... | 20 | 1.538462 | 10 | 10 |
b9a0fa0ec1cde9d461a6a546a18c3605e34efdce | .travis.yml | .travis.yml | language: java
jdk:
- oraclejdk8
sudo: true
before_install:
- sudo apt-get -qq update
- sudo apt-get install -y ntp
- sudo service ntp start
| language: java
jdk:
- oraclejdk8
sudo: true
before_install:
- sudo apt-get -qq update
- sudo apt-get install -y ntp
- sudo service ntp start
script:
- ./gradlew check
- gradle publishToMavenLocal
- cd examples/order && ./gradlew check
| Include examples into the test sequence | Include examples into the test sequence
| YAML | mpl-2.0 | eventsourcing/es4j,yrashk/es4j,yrashk/es4j,eventsourcing/es4j,eventsourcing/es4j | yaml | ## Code Before:
language: java
jdk:
- oraclejdk8
sudo: true
before_install:
- sudo apt-get -qq update
- sudo apt-get install -y ntp
- sudo service ntp start
## Instruction:
Include examples into the test sequence
## Code After:
language: java
jdk:
- oraclejdk8
sudo: true
before_install:
- sudo apt-get -qq... | language: java
jdk:
- oraclejdk8
sudo: true
before_install:
- sudo apt-get -qq update
- sudo apt-get install -y ntp
- sudo service ntp start
+ script:
+ - ./gradlew check
+ - gradle publishToMavenLocal
+ - cd examples/order && ./gradlew check | 4 | 0.5 | 4 | 0 |
2fc2a0a216d4d57e8157622c69b59fe566b885a2 | setup.py | setup.py |
from __future__ import absolute_import, division, print_function
import os, sys
from setuptools import setup, find_packages
setup(
name='towncrier',
maintainer='Amber Brown',
maintainer_email='hawkowl@twistedmatrix.com',
url="https://github.com/hawkowl/towncrier",
classifiers = [
"Intend... |
from __future__ import absolute_import, division, print_function
import os, sys
from setuptools import setup, find_packages
setup(
name='towncrier',
maintainer='Amber Brown',
maintainer_email='hawkowl@twistedmatrix.com',
url="https://github.com/hawkowl/towncrier",
classifiers = [
"Intend... | Stop being a legacy owl | Stop being a legacy owl | Python | mit | hawkowl/towncrier | python | ## Code Before:
from __future__ import absolute_import, division, print_function
import os, sys
from setuptools import setup, find_packages
setup(
name='towncrier',
maintainer='Amber Brown',
maintainer_email='hawkowl@twistedmatrix.com',
url="https://github.com/hawkowl/towncrier",
classifiers = [... |
from __future__ import absolute_import, division, print_function
import os, sys
from setuptools import setup, find_packages
setup(
name='towncrier',
maintainer='Amber Brown',
maintainer_email='hawkowl@twistedmatrix.com',
url="https://github.com/hawkowl/towncrier",
class... | 1 | 0.023256 | 1 | 0 |
4f4b7491df1566cb0804f02c9da720d2b9da2550 | plugins/merge_helper/lib/db.rb | plugins/merge_helper/lib/db.rb | module Jetpants
class DB
def aggregator?
return @aggregator unless @aggregator.nil?
version_info = query_return_array('SHOW VARIABLES LIKE "%version%"')
@aggregator = !version_info[:version_comment].nil? && version_info[:version_comment].downcase.include?("mariadb")
end
end
end
| module Jetpants
class DB
def aggregator?
return @aggregator unless @aggregator.nil?
version_info = query_return_array('SHOW VARIABLES LIKE "version"')
@aggregator = !version_info.nil? && !version_info.empty? && version_info.first[:Value].downcase.include?("mariadb")
end
end
end
| Change aggregation flag check logic | Change aggregation flag check logic
| Ruby | apache-2.0 | fgbreel/jetpants,yonglehou/jetpants,fgbreel/jetpants,dallasmarlow/jetpants,yonglehou/jetpants,tumblr/jetpants,tumblr/jetpants,tumblr/jetpants,dallasmarlow/jetpants,tumblr/jetpants | ruby | ## Code Before:
module Jetpants
class DB
def aggregator?
return @aggregator unless @aggregator.nil?
version_info = query_return_array('SHOW VARIABLES LIKE "%version%"')
@aggregator = !version_info[:version_comment].nil? && version_info[:version_comment].downcase.include?("mariadb")
end
en... | module Jetpants
class DB
def aggregator?
return @aggregator unless @aggregator.nil?
- version_info = query_return_array('SHOW VARIABLES LIKE "%version%"')
? - -
+ version_info = query_return_array('SHOW VARIABLES LIKE "... | 4 | 0.4 | 2 | 2 |
fbc4bacd3b7551f6e1da2ff8be0e484c4e85fa53 | .travis.yml | .travis.yml | language: ruby
rvm:
- 2.4
before_script:
- bundle exec rake db:migrate
- npm install -g istanbul | language: ruby
rvm:
- 2.4
before_script:
- bundle exec rake db:schema:load
- npm install -g istanbul | Use db:schema:load on tests, as it's faster | Use db:schema:load on tests, as it's faster
| YAML | mit | aszecsei/dexterity.io,aszecsei/dexterity.io,aszecsei/dexterity.io | yaml | ## Code Before:
language: ruby
rvm:
- 2.4
before_script:
- bundle exec rake db:migrate
- npm install -g istanbul
## Instruction:
Use db:schema:load on tests, as it's faster
## Code After:
language: ruby
rvm:
- 2.4
before_script:
- bundle exec rake db:schema:load
- npm install -g istanbul | language: ruby
rvm:
- 2.4
before_script:
- - bundle exec rake db:migrate
? --- ^^
+ - bundle exec rake db:schema:load
? ++++ ^^^^^
- npm install -g istanbul | 2 | 0.285714 | 1 | 1 |
2f637bd7450f1ada3de59b0fc86789ea72fef86b | sys/modules/linux/linux.sh | sys/modules/linux/linux.sh |
FOUND=`kldstat -v | egrep 'linux(aout|elf)'`
if [ "x$FOUND" != x ] ; then
echo Linux driver already loaded
exit 1
else
kldload linux
fi
|
FOUND=`kldstat -v | egrep 'linux(aout|elf)'`
exitcode=0
if [ "x$FOUND" != x ] ; then
echo Linux driver already loaded
exitcode=1
else
kldload linux
exitcode=$?
fi
if [ -f /compat/linux/sbin/ldconfig ] ; then
/compat/linux/sbin/ldconfig
fi
exit $ex... | Add a run of Linux ldconfig. | Add a run of Linux ldconfig.
| Shell | bsd-3-clause | jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase,jrobhoward/SCADAbase | shell | ## Code Before:
FOUND=`kldstat -v | egrep 'linux(aout|elf)'`
if [ "x$FOUND" != x ] ; then
echo Linux driver already loaded
exit 1
else
kldload linux
fi
## Instruction:
Add a run of Linux ldconfig.
## Code After:
FOUND=`kldstat -v | egrep 'linux(aout... |
FOUND=`kldstat -v | egrep 'linux(aout|elf)'`
+ exitcode=0
+
if [ "x$FOUND" != x ] ; then
echo Linux driver already loaded
- exit 1
+ exitcode=1
else
kldload linux
+ exitcode=$?
fi
+
+ if [ -f /compat/linux/sbin/ldconfig ] ; then
+ ... | 11 | 1.222222 | 10 | 1 |
4c84845e6264c186347c6d347a30d90f699ef036 | app/Http/Controllers/ChopsController.php | app/Http/Controllers/ChopsController.php | <?php
namespace ChopBox\Http\Controllers;
use ChopBox\helpers\PostChop;
use ChopBox\Http\Requests\ChopsFormRequest;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Input as Input;
class ChopsController extends Controller
{
/**
* Store posted chops
*
* @param Request $request
... | <?php
namespace ChopBox\Http\Controllers;
use ChopBox\helpers\PostChop;
use Illuminate\Support\Facades\Auth;
use ChopBox\Http\Requests\ChopsFormRequest;
use Illuminate\Support\Facades\Input as Input;
class ChopsController extends Controller
{
/**
* Store posted chops
*
* @param Request $request
... | Fix indentation and arrange imports from shortest tolongest | [ChopBox] Fix indentation and arrange imports from shortest tolongest
| PHP | mit | andela/chopbox,andela/chopbox | php | ## Code Before:
<?php
namespace ChopBox\Http\Controllers;
use ChopBox\helpers\PostChop;
use ChopBox\Http\Requests\ChopsFormRequest;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Input as Input;
class ChopsController extends Controller
{
/**
* Store posted chops
*
* @param Re... | <?php
namespace ChopBox\Http\Controllers;
use ChopBox\helpers\PostChop;
+ use Illuminate\Support\Facades\Auth;
use ChopBox\Http\Requests\ChopsFormRequest;
- use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Input as Input;
class ChopsController extends Controller
{
/**
... | 4 | 0.114286 | 1 | 3 |
101a7c8e0e26089d6d1deb4e7728e4eb59274b74 | app/main/forms.py | app/main/forms.py | from flask.ext.wtf import Form
from wtforms import validators
from dmutils.forms import StripWhitespaceStringField
from .. import data_api_client
class AdminEmailAddressValidator(object):
def __init__(self, message=None):
self.message = message
def __call__(self, form, field):
if not data_... | from flask.ext.wtf import Form
from wtforms import RadioField, validators
from dmutils.forms import StripWhitespaceStringField
from .. import data_api_client
class AdminEmailAddressValidator(object):
def __init__(self, message=None):
self.message = message
def __call__(self, form, field):
... | Add InviteAdminForm with email_address and role fields | Add InviteAdminForm with email_address and role fields
| Python | mit | alphagov/digitalmarketplace-admin-frontend,alphagov/digitalmarketplace-admin-frontend,alphagov/digitalmarketplace-admin-frontend,alphagov/digitalmarketplace-admin-frontend | python | ## Code Before:
from flask.ext.wtf import Form
from wtforms import validators
from dmutils.forms import StripWhitespaceStringField
from .. import data_api_client
class AdminEmailAddressValidator(object):
def __init__(self, message=None):
self.message = message
def __call__(self, form, field):
... | from flask.ext.wtf import Form
- from wtforms import validators
+ from wtforms import RadioField, validators
? ++++++++++++
from dmutils.forms import StripWhitespaceStringField
from .. import data_api_client
class AdminEmailAddressValidator(object):
def __init__(self, m... | 28 | 0.777778 | 27 | 1 |
0367796657012e6de50acc4e6f8bafef340b3213 | codecov.yml | codecov.yml | coverage:
status:
patch: false
changes: false
project:
default:
target: auto
comment: off
ignore:
- "/bin"
| coverage:
status:
patch: false
changes: false
project:
default:
target: auto
threshold: 0.1%
comment: off
ignore:
- "/bin"
| Adjust coverage thresholds for PRs | Adjust coverage thresholds for PRs
| YAML | apache-2.0 | ampproject/amp-toolbox-php,ampproject/amp-toolbox-php | yaml | ## Code Before:
coverage:
status:
patch: false
changes: false
project:
default:
target: auto
comment: off
ignore:
- "/bin"
## Instruction:
Adjust coverage thresholds for PRs
## Code After:
coverage:
status:
patch: false
changes: false
project:
default:
targe... | coverage:
status:
patch: false
changes: false
project:
default:
target: auto
+ threshold: 0.1%
comment: off
ignore:
- "/bin" | 1 | 0.083333 | 1 | 0 |
37a155226210640f16018e1033d4769b2fb36909 | gitst.c | gitst.c |
int
main(int argc, char **argv)
{
char* gitbuff;
int out = run_proc(&gitbuff, "git", "branch", "--list", 0);
//int out = run_proc(&gitbuff, "ls", "-l", "-h", 0);
if (out != 0)
{
fprintf(stderr, "Error running subprocess:%d\n", out);
exit(1);
}
//printf("run_proc exit code = %d\nresponse= '''%s''... |
int
main(int argc, char **argv)
{
char* gitbuff;
int out = run_proc(&gitbuff, "git", "branch", "--list", 0);
if (out != 0)
{
exit(1);
}
char *token;
char *sep=" \r\n";
int next = 0;
while((token = strsep(&gitbuff, sep)) != NULL)
{
if (token[0] == '*') {
token = strsep(&gitbuff, sep)... | Use strsep to split output | Use strsep to split output
| C | bsd-3-clause | wnh/prompt_utils | c | ## Code Before:
int
main(int argc, char **argv)
{
char* gitbuff;
int out = run_proc(&gitbuff, "git", "branch", "--list", 0);
//int out = run_proc(&gitbuff, "ls", "-l", "-h", 0);
if (out != 0)
{
fprintf(stderr, "Error running subprocess:%d\n", out);
exit(1);
}
//printf("run_proc exit code = %d\nr... |
int
main(int argc, char **argv)
{
-
char* gitbuff;
int out = run_proc(&gitbuff, "git", "branch", "--list", 0);
- //int out = run_proc(&gitbuff, "ls", "-l", "-h", 0);
if (out != 0)
{
- fprintf(stderr, "Error running subprocess:%d\n", out);
exit(1);
}
- //printf("run_proc exit ... | 30 | 0.9375 | 11 | 19 |
31fe9a0d06fc2fbba018632a4f96ae7ca92b5d87 | app/models/manageiq/providers/openstack/cloud_manager/vnf/status.rb | app/models/manageiq/providers/openstack/cloud_manager/vnf/status.rb | class ManageIQ::Providers::Openstack::CloudManager::Vnf::Status < ::OrchestrationStack::Status
def succeeded?
status.downcase == "active"
end
def failed?
status.downcase =~ /failed$/
end
def rolled_back?
status.downcase == "rollback_complete"
end
def deleted?
status.downcase == "delete_... | class ManageIQ::Providers::Openstack::CloudManager::Vnf::Status < ::OrchestrationStack::Status
def succeeded?
status.downcase == "active"
end
def failed?
status.downcase =~ /failed$/ || status.downcase == "error"
end
def rolled_back?
status.downcase == "rollback_complete"
end
def deleted?
... | Handle VNF error state correctly | Handle VNF error state correctly
Handle VNF error state correctly
| Ruby | apache-2.0 | kbrock/manageiq,maas-ufcg/manageiq,hstastna/manageiq,andyvesel/manageiq,josejulio/manageiq,josejulio/manageiq,KevinLoiseau/manageiq,gerikis/manageiq,NickLaMuro/manageiq,syncrou/manageiq,ailisp/manageiq,syncrou/manageiq,jntullo/manageiq,fbladilo/manageiq,pkomanek/manageiq,israel-hdez/manageiq,djberg96/manageiq,mkanoor/m... | ruby | ## Code Before:
class ManageIQ::Providers::Openstack::CloudManager::Vnf::Status < ::OrchestrationStack::Status
def succeeded?
status.downcase == "active"
end
def failed?
status.downcase =~ /failed$/
end
def rolled_back?
status.downcase == "rollback_complete"
end
def deleted?
status.down... | class ManageIQ::Providers::Openstack::CloudManager::Vnf::Status < ::OrchestrationStack::Status
def succeeded?
status.downcase == "active"
end
def failed?
- status.downcase =~ /failed$/
+ status.downcase =~ /failed$/ || status.downcase == "error"
end
def rolled_back?
statu... | 2 | 0.095238 | 1 | 1 |
be491a7fbc812722a9d6a973463f0999eeef0185 | CHANGELOG.md | CHANGELOG.md |
* Queryset cache on generic view
* Add image thumb on ArticleBox
* Send current site to template ``{{ SITE }}``
* In /rss feed, filter channels by **published** and **include_in_main_rss**
* RSS Feed now renders in a template
* Flatpage is content type Article
* **Hotfix** fix *memory leak* (articles generic view)
* C... |
* Content type (Container)
* Isoled boxes application
* ContainerBox, generic box (concept)
* Used Container in all application
* Archives, file manager
* Images used archives
* Used RST on README, pypi compatibility
* Add contrib pattern (like django)
* Upgrade haystack to 2.0 (stable)
* Opps Generic Views
* * New vi... | Update changelog to version 0.2 | Update changelog to version 0.2
| Markdown | mit | YACOWS/opps,YACOWS/opps,jeanmask/opps,opps/opps,williamroot/opps,jeanmask/opps,opps/opps,williamroot/opps,jeanmask/opps,YACOWS/opps,williamroot/opps,opps/opps,YACOWS/opps,williamroot/opps,jeanmask/opps,opps/opps | markdown | ## Code Before:
* Queryset cache on generic view
* Add image thumb on ArticleBox
* Send current site to template ``{{ SITE }}``
* In /rss feed, filter channels by **published** and **include_in_main_rss**
* RSS Feed now renders in a template
* Flatpage is content type Article
* **Hotfix** fix *memory leak* (articles g... | +
+ * Content type (Container)
+ * Isoled boxes application
+ * ContainerBox, generic box (concept)
+ * Used Container in all application
+ * Archives, file manager
+ * Images used archives
+ * Used RST on README, pypi compatibility
+ * Add contrib pattern (like django)
+ * Upgrade haystack to 2.0 (stable)
+ * Opps Ge... | 16 | 0.666667 | 16 | 0 |
35786af3235a2ea0176f014807cfaaa947696188 | .travis.yml | .travis.yml | language: ruby
before_script:
- echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
script: "bundle exec rake spec"
rvm:
- 1.9.3
- 2.0.0
env:
- PUPPET_GEM_VERSION="~> 3.1.0"
- PUPPET_GEM_VERSION="~> 3.2.0"
- PUPPET_GEM_VERSION="~> 3.3.0"
- PUPPET_GEM_VERSION="~> 3.4.0"
b... | language: ruby
before_script:
- echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
script: "bundle exec rake spec"
rvm:
- 1.9.3
- 2.0.0
env:
- PUPPET_GEM_VERSION="~> 3.1.0"
- PUPPET_GEM_VERSION="~> 3.2.0"
- PUPPET_GEM_VERSION="~> 3.3.0"
- PUPPET_GEM_VERSION="~> 3.4.0"
b... | Allow failures for 3.4.x as it is a known bug with module_data | Allow failures for 3.4.x as it is a known bug with module_data
| YAML | apache-2.0 | cyberious/puppet-windows_java | yaml | ## Code Before:
language: ruby
before_script:
- echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
script: "bundle exec rake spec"
rvm:
- 1.9.3
- 2.0.0
env:
- PUPPET_GEM_VERSION="~> 3.1.0"
- PUPPET_GEM_VERSION="~> 3.2.0"
- PUPPET_GEM_VERSION="~> 3.3.0"
- PUPPET_GEM_VERSION="~> 3.4.... | language: ruby
before_script:
- echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
script: "bundle exec rake spec"
rvm:
- 1.9.3
- 2.0.0
env:
- PUPPET_GEM_VERSION="~> 3.1.0"
- PUPPET_GEM_VERSION="~> 3.2.0"
- PUPPET_GEM_VERSION="~> 3.3.0"
- PUPPET_GEM_VERSION=... | 2 | 0.086957 | 2 | 0 |
95650d391e04f6e56da8a82085e92ac5b0c8d4f2 | scripts/xcode-server.coffee | scripts/xcode-server.coffee |
url = require('url')
querystring = require('querystring')
module.exports = (robot) ->
robot.router.get "/hubot/xcode-publish-notify", (req, res) ->
query = querystring.parse(url.parse(req.url).query)
app = query.app || null
success = query.success == "true" || false
version = query.version || null
... |
url = require('url')
querystring = require('querystring')
module.exports = (robot) ->
robot.router.get "/hubot/xcode-publish-notify", (req, res) ->
query = querystring.parse(url.parse(req.url).query)
app = query.app || null
success = query.success == "true" || false
version = query.version || null
... | Update copy for a more natural sentence | Update copy for a more natural sentence
| CoffeeScript | mit | brandnetworks/our-product-slack-hubot | coffeescript | ## Code Before:
url = require('url')
querystring = require('querystring')
module.exports = (robot) ->
robot.router.get "/hubot/xcode-publish-notify", (req, res) ->
query = querystring.parse(url.parse(req.url).query)
app = query.app || null
success = query.success == "true" || false
version = query.v... |
url = require('url')
querystring = require('querystring')
module.exports = (robot) ->
robot.router.get "/hubot/xcode-publish-notify", (req, res) ->
query = querystring.parse(url.parse(req.url).query)
app = query.app || null
success = query.success == "true" || false
version = que... | 2 | 0.095238 | 1 | 1 |
08666f1c6270c81ec36b60a18eaf40c9879e8c8a | _config.yml | _config.yml | title: Restify
email: wblankenship@netflix.com
description:
Jekyll Template for Project Websites
providing documentation and blog post pages.
baseurl: "" # the subpath of your site, e.g. /blog/
url: https://restify.github.io # the base hostname & protocol for your site
git_address: https://github.com/restify/node-... | title: Restify
email: wblankenship@netflix.com
description:
A Node.js web service framework optimized for building semantically correct RESTful web services ready for production use at scale. restify optimizes for introspection and perfromance, and is used in some of the largest Node.js deployments on Earth.
baseurl: ... | Make it have a better description in the googles | Make it have a better description in the googles
Yeah this is showing up in search, it annoyed me so heres a fix | YAML | mit | restify/restify.github.io,restify/restify.github.io,restify/restify.github.io | yaml | ## Code Before:
title: Restify
email: wblankenship@netflix.com
description:
Jekyll Template for Project Websites
providing documentation and blog post pages.
baseurl: "" # the subpath of your site, e.g. /blog/
url: https://restify.github.io # the base hostname & protocol for your site
git_address: https://github.c... | title: Restify
email: wblankenship@netflix.com
description:
+ A Node.js web service framework optimized for building semantically correct RESTful web services ready for production use at scale. restify optimizes for introspection and perfromance, and is used in some of the largest Node.js deployments on Earth.
- ... | 3 | 0.058824 | 1 | 2 |
66ae3d60f4bbbe9f39107828ee89ce9d6c89ffa5 | railseventstore.org/config.rb | railseventstore.org/config.rb | activate :aria_current
activate :directory_indexes
activate :syntax do |syntax|
syntax.css_class = "syntax-highlight"
end
set :markdown, tables: true, autolink: true, gh_blockcode: true, fenced_code_blocks: true, with_toc_data: false
set :markdown_engine, :redcarpet
set :res_version, File.read('../RES_VERSION')
pag... | activate :aria_current
activate :directory_indexes
activate :syntax do |syntax|
syntax.css_class = "syntax-highlight"
end
set :markdown, tables: true, autolink: true, gh_blockcode: true, fenced_code_blocks: true, with_toc_data: false, no_intra_emphasis: true
set :markdown_engine, :redcarpet
set :res_version, File.re... | Make it easier on _ in names. | Make it easier on _ in names.
| Ruby | mit | RailsEventStore/rails_event_store,mpraglowski/rails_event_store,arkency/rails_event_store,RailsEventStore/rails_event_store,mpraglowski/rails_event_store,RailsEventStore/rails_event_store,RailsEventStore/rails_event_store,mpraglowski/rails_event_store,arkency/rails_event_store,mpraglowski/rails_event_store,arkency/rail... | ruby | ## Code Before:
activate :aria_current
activate :directory_indexes
activate :syntax do |syntax|
syntax.css_class = "syntax-highlight"
end
set :markdown, tables: true, autolink: true, gh_blockcode: true, fenced_code_blocks: true, with_toc_data: false
set :markdown_engine, :redcarpet
set :res_version, File.read('../RE... | activate :aria_current
activate :directory_indexes
activate :syntax do |syntax|
syntax.css_class = "syntax-highlight"
end
- set :markdown, tables: true, autolink: true, gh_blockcode: true, fenced_code_blocks: true, with_toc_data: false
+ set :markdown, tables: true, autolink: true, gh_blockcode: true, fe... | 2 | 0.166667 | 1 | 1 |
eee37a4079171491ff260102dcf7144f7e51d5ac | _includes/tag_link_formatter.html | _includes/tag_link_formatter.html | {% comment %}
Format a link to a posts-with-tag page from "tag", a _data/tags.yml object, and "tag_separator".
{% endcomment %}
<a href="{{ site.baseurl }}/tag/{{ include.tag.slug }}">{{ include.tag.name }}</a>{% if forloop.last == false %}{{ include.tag_separator }}{% endif %}
| {% comment %}
Format a link to a posts-with-tag page from "tag", a _data/tags.yml object, and "tag_separator".
{% endcomment %}
{% if site.permalink == 'pretty' %}
{% capture tag_page %}{{ include.tag.slug }}/{% endcapture %}
{% else %}
{% capture tag_page %}{{ include.tag.slug }}.html{% endcapture %}
{% endif %... | Fix tag links for 'ordinal', 'date', 'none' permalinks | Fix tag links for 'ordinal', 'date', 'none' permalinks
| HTML | mit | awwnb/awwnb.github.io,awwnb/awwnb.github.io,awwnb/awwnb.github.io,awwnb/awwnb.github.io | html | ## Code Before:
{% comment %}
Format a link to a posts-with-tag page from "tag", a _data/tags.yml object, and "tag_separator".
{% endcomment %}
<a href="{{ site.baseurl }}/tag/{{ include.tag.slug }}">{{ include.tag.name }}</a>{% if forloop.last == false %}{{ include.tag_separator }}{% endif %}
## Instruction:
Fix t... | {% comment %}
Format a link to a posts-with-tag page from "tag", a _data/tags.yml object, and "tag_separator".
{% endcomment %}
+ {% if site.permalink == 'pretty' %}
+ {% capture tag_page %}{{ include.tag.slug }}/{% endcapture %}
+ {% else %}
+ {% capture tag_page %}{{ include.tag.slug }}.html{% endcaptu... | 8 | 1.6 | 7 | 1 |
32740ee0fe320bb929189f500e9cde3d336c1aee | src/character/audio.rs | src/character/audio.rs | use std::fs::File;
use std::io::BufReader;
use rodio;
use rodio::Sink;
use game::constants::PISTOL_AUDIO_PATH;
pub struct CharacterAudio {
sink: Sink,
}
impl CharacterAudio {
pub fn new() -> CharacterAudio {
let endpoint = rodio::get_default_endpoint().unwrap();
CharacterAudio {
sink: Sink::new(&end... | use std::fs::File;
use std::io::BufReader;
use rodio;
use rodio::Sink;
use game::constants::PISTOL_AUDIO_PATH;
pub struct CharacterAudio {
sink: Sink,
}
impl CharacterAudio {
pub fn new() -> CharacterAudio {
#[allow(deprecated)]
let endpoint = rodio::get_default_endpoint().unwrap();
CharacterAudio {
... | Allow use of deprecated "get_default_endpoint" | Allow use of deprecated "get_default_endpoint" | Rust | apache-2.0 | Laastine/zombie-shooter,Laastine/zombie-shooter | rust | ## Code Before:
use std::fs::File;
use std::io::BufReader;
use rodio;
use rodio::Sink;
use game::constants::PISTOL_AUDIO_PATH;
pub struct CharacterAudio {
sink: Sink,
}
impl CharacterAudio {
pub fn new() -> CharacterAudio {
let endpoint = rodio::get_default_endpoint().unwrap();
CharacterAudio {
sink... | use std::fs::File;
use std::io::BufReader;
use rodio;
use rodio::Sink;
use game::constants::PISTOL_AUDIO_PATH;
pub struct CharacterAudio {
sink: Sink,
}
impl CharacterAudio {
pub fn new() -> CharacterAudio {
+ #[allow(deprecated)]
let endpoint = rodio::get_default_endpoint().unwr... | 1 | 0.038462 | 1 | 0 |
de7dfdc176456db60319e12d22ad66d8b62ad9e9 | tox.ini | tox.ini | [tox]
envlist =
py3
flake8
[testenv]
commands =
coverage run --source pyecore -m pytest -v --capture=sys
coverage report -m
deps =
coverage
pytest
[testenv:flake8]
commands =
flake8 pyecore setup.py
deps =
flake8
| [tox]
envlist =
py3
flake8
[testenv]
commands =
coverage run --source pyecore -m pytest -v --capture=sys
coverage report -m
deps =
coverage
pytest
[testenv:flake8]
commands =
flake8 pyecore setup.py
deps =
flake8
[testenv:cosmic_ray]
commands =
cosmic-ray --verbose run --test-runn... | Configure cosmic_ray for manual usage | Configure cosmic_ray for manual usage
| INI | bsd-3-clause | pyecore/pyecore,aranega/pyecore | ini | ## Code Before:
[tox]
envlist =
py3
flake8
[testenv]
commands =
coverage run --source pyecore -m pytest -v --capture=sys
coverage report -m
deps =
coverage
pytest
[testenv:flake8]
commands =
flake8 pyecore setup.py
deps =
flake8
## Instruction:
Configure cosmic_ray for manual usage
#... | [tox]
envlist =
py3
flake8
[testenv]
commands =
coverage run --source pyecore -m pytest -v --capture=sys
coverage report -m
deps =
coverage
pytest
[testenv:flake8]
commands =
flake8 pyecore setup.py
deps =
flake8
+
+ [testenv:cosmic_ray]
+ commands ... | 8 | 0.444444 | 8 | 0 |
3d8ca43e1283bc2e785225a55662819ea96aa252 | app/controllers/waitingroom_controller.rb | app/controllers/waitingroom_controller.rb | class WaitingroomController < ApplicationController
def new
end
def index
end
def check
if request.xhr?
if Waitingroom.all.length == 1
render json: Waitingroom.all.length.to_json
elsif Waitingroom.all.length == 2
players = Waitingroom.first(2).map { |e| e.party_id }
... | class WaitingroomController < ApplicationController
def new
end
def index
end
def check
if request.xhr?
if Waitingroom.all.length == 1
render json: Waitingroom.all.length.to_json
elsif Waitingroom.all.length == 2
players = Waitingroom.first(2).map { |e| e.party_id }
... | Make all quizzes hardcoded to Question 1. | Make all quizzes hardcoded to Question 1.
| Ruby | mit | susancal/Waitr,susancal/Waitr,susancal/Waitr | ruby | ## Code Before:
class WaitingroomController < ApplicationController
def new
end
def index
end
def check
if request.xhr?
if Waitingroom.all.length == 1
render json: Waitingroom.all.length.to_json
elsif Waitingroom.all.length == 2
players = Waitingroom.first(2).map { |e| e.par... | class WaitingroomController < ApplicationController
def new
end
def index
end
def check
if request.xhr?
if Waitingroom.all.length == 1
render json: Waitingroom.all.length.to_json
elsif Waitingroom.all.length == 2
players = Waitingroom.first(2).map... | 2 | 0.04878 | 1 | 1 |
d834923e7b62d639f7005a413ebd3fb3cb86b81a | lib/Userbin/Resource.php | lib/Userbin/Resource.php | <?php
class Userbin_Resource
{
protected $parent = null;
protected $items = null;
public function __construct($model, $items=null)
{
$this->model = $model;
if (is_array($items)) {
$this->items = $this->addItems($items);
}
}
protected function createModel($attributes=null)
{
$ins... | <?php
class Userbin_Resource
{
protected $parent = null;
protected $items = null;
public function __construct($model, $items=null)
{
$this->model = $model;
if (is_array($items)) {
$this->items = $this->addItems($items);
}
}
protected function createModel($attributes=null)
{
$ins... | Fix destroy if there is no id | Fix destroy if there is no id
| PHP | mit | castle/castle-php,castle/castle-php | php | ## Code Before:
<?php
class Userbin_Resource
{
protected $parent = null;
protected $items = null;
public function __construct($model, $items=null)
{
$this->model = $model;
if (is_array($items)) {
$this->items = $this->addItems($items);
}
}
protected function createModel($attributes=nu... | <?php
class Userbin_Resource
{
protected $parent = null;
protected $items = null;
public function __construct($model, $items=null)
{
$this->model = $model;
if (is_array($items)) {
$this->items = $this->addItems($items);
}
}
protected function createMo... | 4 | 0.057971 | 2 | 2 |
c7b4feb2c16236c771f8601d3ca5964a957643c9 | hireme/index.html | hireme/index.html | ---
layout: page
title: Hire Me
published: true
---
<p>I'm a freelance web programmer, and I'm <span class="tag available">available</span> for hire.</p>
<p>
I specialize in planning and building Javascript front end applications using tools like React Native or Vue. I also build Node-based REST APIs and full-stack J... | ---
layout: page
title: Hire Me
published: true
---
<p>I'm a freelance web programmer, and I'm <span class="tag available">available</span> for hire.</p>
<p>
I specialize in planning and building Javascript front end applications using modern tools. I also build Node-based REST APIs and full-stack Javascript apps.
</... | Change wording on hireme page slightly | Change wording on hireme page slightly
| HTML | mit | HiccupinGminor/HiccupinGminor.github.io,HiccupinGminor/HiccupinGminor.github.io,HiccupinGminor/HiccupinGminor.github.io | html | ## Code Before:
---
layout: page
title: Hire Me
published: true
---
<p>I'm a freelance web programmer, and I'm <span class="tag available">available</span> for hire.</p>
<p>
I specialize in planning and building Javascript front end applications using tools like React Native or Vue. I also build Node-based REST APIs ... | ---
layout: page
title: Hire Me
published: true
---
<p>I'm a freelance web programmer, and I'm <span class="tag available">available</span> for hire.</p>
<p>
- I specialize in planning and building Javascript front end applications using tools like React Native or Vue. I also build Node-based REST APIs ... | 2 | 0.2 | 1 | 1 |
80776e99dd9d57f37f6f3641962ca0e542e908f3 | README.md | README.md | This is the personal website of Sara Moore, served Github Pages as a 'user page.' This site was built using [Jekyll](http://jekyllrb.com/) and styled with [Bootstrap](http://getbootstrap.com/), as well as modified versions of the [sustain](http://www.github.com/biomadeira/sustain) and [vitae](http://github.com/biomadei... | [](https://travis-ci.org/saraemoore/saraemoore.github.io)
This is the personal website of Sara Moore, served Github Pages as a 'user page.' This site was built using [Jekyll](http://jekyllrb.com/) and styled with [Bootstrap](http:/... | Add travis ci build status badge | Add travis ci build status badge | Markdown | mit | saraemoore/saraemoore.github.io,saraemoore/saraemoore.github.io,saraemoore/saraemoore.github.io | markdown | ## Code Before:
This is the personal website of Sara Moore, served Github Pages as a 'user page.' This site was built using [Jekyll](http://jekyllrb.com/) and styled with [Bootstrap](http://getbootstrap.com/), as well as modified versions of the [sustain](http://www.github.com/biomadeira/sustain) and [vitae](http://git... | + [](https://travis-ci.org/saraemoore/saraemoore.github.io)
+
This is the personal website of Sara Moore, served Github Pages as a 'user page.' This site was built using [Jekyll](http://jekyllrb.com/) and styled with [Bootstrap](... | 2 | 2 | 2 | 0 |
40109c646c4fb51ae7d463f0272e6c47b75dabc6 | .travis.yml | .travis.yml | before_install: sudo apt-get install libzmq3-dev
script: bundle exec rspec
language: ruby
rvm:
- 1.9
- 2.0
- 2.1
- rbx-2
notifications:
email: false
irc:
channels:
- "chat.freenode.net#wires" | before_install:
"git clone https://github.com/$LIBZMQ_REPO libzmq \
&& cd libzmq \
&& ./autogen.sh \
&& ./configure --with-pgm \
&& make \
&& sudo make install ... | Add second dimension to Travis CI build matrix - libzmq version 3 and 4 | Add second dimension to Travis CI build matrix - libzmq version 3 and 4
| YAML | mit | jemc/0mq | yaml | ## Code Before:
before_install: sudo apt-get install libzmq3-dev
script: bundle exec rspec
language: ruby
rvm:
- 1.9
- 2.0
- 2.1
- rbx-2
notifications:
email: false
irc:
channels:
- "chat.freenode.net#wires"
## Instruction:
Add second dimension to Travis CI build matrix - libzmq version 3 and 4
#... | - before_install: sudo apt-get install libzmq3-dev
+ before_install:
+ "git clone https://github.com/$LIBZMQ_REPO libzmq \
+ && cd libzmq \
+ && ./autogen.sh \
+ && ./configure --with-pgm \
+ && make ... | 13 | 1 | 12 | 1 |
258fcd1ce0f69a0dbe883480abb35b152b6a4b0b | .config/Code/User/settings.json | .config/Code/User/settings.json | {
"telemetry.telemetryLevel": "off",
"workbench.colorTheme": "Gruvbox Dark (Hard)",
"editor.formatOnSave": true,
"window.titleBarStyle": "custom",
"window.zoomLevel": 1,
"editor.inlayHints.enabled": "offUnlessPressed",
"keyboard.dispatch": "keyCode",
"editor.bracketPairColorization.enabl... | {
"telemetry.telemetryLevel": "off",
"workbench.colorTheme": "Gruvbox Dark (Hard)",
"editor.formatOnSave": true,
"window.titleBarStyle": "custom",
"window.zoomLevel": 1,
"editor.inlayHints.enabled": "offUnlessPressed",
"keyboard.dispatch": "keyCode",
"editor.bracketPairColorization.enabl... | Add ruler at 80 columns | Add ruler at 80 columns
| JSON | isc | reillysiemens/dotfiles,reillysiemens/dotfiles | json | ## Code Before:
{
"telemetry.telemetryLevel": "off",
"workbench.colorTheme": "Gruvbox Dark (Hard)",
"editor.formatOnSave": true,
"window.titleBarStyle": "custom",
"window.zoomLevel": 1,
"editor.inlayHints.enabled": "offUnlessPressed",
"keyboard.dispatch": "keyCode",
"editor.bracketPairCo... | {
"telemetry.telemetryLevel": "off",
"workbench.colorTheme": "Gruvbox Dark (Hard)",
"editor.formatOnSave": true,
"window.titleBarStyle": "custom",
"window.zoomLevel": 1,
"editor.inlayHints.enabled": "offUnlessPressed",
"keyboard.dispatch": "keyCode",
"editor.bracketPair... | 8 | 0.421053 | 6 | 2 |
448cee0d641ec8b3f75774a339d3044d6a86c037 | src/core/team-core.js | src/core/team-core.js | const {knex} = require('../util/database').connect();
import _ from 'lodash';
import {deepChangeKeyCase} from '../util';
function getTeams() {
return knex.raw(`SELECT teams.id, teams.name, SUM(COALESCE(action_types.value, 0)) AS score
FROM teams
LEFT JOIN actions ON teams.id = actions.team_id
LEFT JOIN action_... | const {knex} = require('../util/database').connect();
import _ from 'lodash';
import {deepChangeKeyCase} from '../util';
function getTeams() {
return knex.raw(`SELECT teams.id, teams.name, teams.image_path, SUM(COALESCE(action_types.value, 0)) AS score
FROM teams
LEFT JOIN actions ON teams.id = actions.team_id
... | Return also teams.image_path from getTeams | Return also teams.image_path from getTeams
| JavaScript | mit | futurice/wappuapp-backend,kaupunki-apina/prahapp-backend,futurice/wappuapp-backend,kaupunki-apina/prahapp-backend | javascript | ## Code Before:
const {knex} = require('../util/database').connect();
import _ from 'lodash';
import {deepChangeKeyCase} from '../util';
function getTeams() {
return knex.raw(`SELECT teams.id, teams.name, SUM(COALESCE(action_types.value, 0)) AS score
FROM teams
LEFT JOIN actions ON teams.id = actions.team_id
L... | const {knex} = require('../util/database').connect();
import _ from 'lodash';
import {deepChangeKeyCase} from '../util';
function getTeams() {
- return knex.raw(`SELECT teams.id, teams.name, SUM(COALESCE(action_types.value, 0)) AS score
+ return knex.raw(`SELECT teams.id, teams.name, teams.image_path, SU... | 2 | 0.105263 | 1 | 1 |
0b5f74f9d0a3ab08b742a537e1e900765f8f52d8 | packages/resourceful-redux/src/utils/get-resources.js | packages/resourceful-redux/src/utils/get-resources.js | // Returns a list of resources by IDs or label
export default function(state, resourceName, idsOrLabel) {
const resourceSlice = state[resourceName];
if (!resourceSlice) {
return [];
}
const resources = resourceSlice.resources;
let idsList;
// This conditional handles the situation where `idsOrLabel` i... | // Returns a list of resources by IDs or list name
export default function(state, resourceName, idsOrList) {
const resourceSlice = state[resourceName];
if (!resourceSlice) {
return [];
}
const resources = resourceSlice.resources;
let idsList;
// This conditional handles the situation where `idsOrList`... | Update getResources to support lists, not labels | Update getResources to support lists, not labels
| JavaScript | mit | jmeas/resourceful-redux,jmeas/resourceful-redux | javascript | ## Code Before:
// Returns a list of resources by IDs or label
export default function(state, resourceName, idsOrLabel) {
const resourceSlice = state[resourceName];
if (!resourceSlice) {
return [];
}
const resources = resourceSlice.resources;
let idsList;
// This conditional handles the situation wher... | - // Returns a list of resources by IDs or label
? ^ -
+ // Returns a list of resources by IDs or list name
? +++++ ^
- export default function(state, resourceName, idsOrLabel) {
? ^... | 21 | 0.636364 | 8 | 13 |
327c39ad26d116eab8f00bc0c80d40c1edf31d2e | _data/sliders.yml | _data/sliders.yml | - selector: fkp_slider
bullets: false
captions: true
images:
- src: /assets/fkp/IMG_20170116_123330.jpg
alt: Waiting for the plane to Vancouver, 2017
- data-src: /assets/fkp/IMG_20170117_172305.jpg
alt: Enjoying some sushi, 2017
- data-src: /assets/fkp/IMG_201803.jpg
alt: Las Vega... | - selector: fkp_slider
bullets: false
captions: true
images:
- src: /assets/fkp/IMG_20170116_123330.jpg
alt: Waiting for the plane to Vancouver, 2017
- data-src: /assets/fkp/IMG_20170116_212756.jpg
alt: Enjoying some sushi, 2017
- data-src: /assets/fkp/IMG_201803.jpg
alt: Las Vegas... | Clean up some code, troubleshoot data-src | Clean up some code, troubleshoot data-src
| YAML | mit | sle3man/sle3man.github.io,sle3man/sle3man.github.io | yaml | ## Code Before:
- selector: fkp_slider
bullets: false
captions: true
images:
- src: /assets/fkp/IMG_20170116_123330.jpg
alt: Waiting for the plane to Vancouver, 2017
- data-src: /assets/fkp/IMG_20170117_172305.jpg
alt: Enjoying some sushi, 2017
- data-src: /assets/fkp/IMG_201803.jpg
... | - selector: fkp_slider
bullets: false
captions: true
images:
-
- src: /assets/fkp/IMG_20170116_123330.jpg
alt: Waiting for the plane to Vancouver, 2017
- - data-src: /assets/fkp/IMG_20170117_172305.jpg
? ------
+ - data-src: /assets/fkp/IMG... | 5 | 0.227273 | 2 | 3 |
10d09367111d610e82344e9616aab98815bf9397 | capture_chessboard.py | capture_chessboard.py | import time
import cv2
import Calibration
# Calibration pattern size
pattern_size = ( 9, 6 )
# Get the camera
camera = cv2.VideoCapture( 1 )
# Acquisition loop
while( True ) :
# Capture image-by-image
_, image = camera.read()
# Display the chessboard on the image
chessboard = Calibration.PreviewChessbo... | import time
import cv2
import numpy as np
import Calibration
# Calibration pattern size
pattern_size = ( 9, 6 )
# Get the camera
camera = cv2.VideoCapture( 0 )
# Acquisition loop
while( True ) :
# Capture image-by-image
_, image = camera.read()
# Copy the image for display
chessboard = np.copy( image )... | Change camera index, and fix the chessboard preview. | Change camera index, and fix the chessboard preview.
| Python | mit | microy/RobotVision,microy/RobotVision | python | ## Code Before:
import time
import cv2
import Calibration
# Calibration pattern size
pattern_size = ( 9, 6 )
# Get the camera
camera = cv2.VideoCapture( 1 )
# Acquisition loop
while( True ) :
# Capture image-by-image
_, image = camera.read()
# Display the chessboard on the image
chessboard = Calibratio... | import time
import cv2
+ import numpy as np
import Calibration
# Calibration pattern size
pattern_size = ( 9, 6 )
# Get the camera
- camera = cv2.VideoCapture( 1 )
? ^
+ camera = cv2.VideoCapture( 0 )
? ^
# Acquisition loop
while( True ) :
... | 7 | 0.241379 | 5 | 2 |
266aaa127973bf296eb1a51ae4ac57c19c8a0029 | .circleci/config.yml | .circleci/config.yml | version: 2.1
orbs:
ruby: circleci/ruby@1.1.2
jobs:
test:
parameters:
version:
type: string
executor:
name: ruby/default
tag: << parameters.version >>
steps:
- checkout
- run:
name: Generate Gemfile.lock
command: bundle lock
- ruby/install... | version: 2.1
orbs:
ruby: circleci/ruby@1.1.2
jobs:
test:
parameters:
version:
type: string
executor:
name: ruby/default
tag: << parameters.version >>
steps:
- checkout
- run:
name: Generate Gemfile.lock
command: bundle lock
- ruby/install... | Use *-node images and install SVGO | Use *-node images and install SVGO
| YAML | mit | jgarber623/svgeez | yaml | ## Code Before:
version: 2.1
orbs:
ruby: circleci/ruby@1.1.2
jobs:
test:
parameters:
version:
type: string
executor:
name: ruby/default
tag: << parameters.version >>
steps:
- checkout
- run:
name: Generate Gemfile.lock
command: bundle lock
... | version: 2.1
orbs:
ruby: circleci/ruby@1.1.2
jobs:
test:
parameters:
version:
type: string
executor:
name: ruby/default
tag: << parameters.version >>
steps:
- checkout
- run:
name: Generate Gemfile.lock
comma... | 11 | 0.25 | 7 | 4 |
859a23790968c84cdbc4fa7467957a3a1ed1e069 | greatbigcrane/project/forms.py | greatbigcrane/project/forms.py |
from django import forms
from project.models import Project
class ProjectForm(forms.ModelForm):
class Meta:
model = Project
class DjangoRecipeForm(forms.Form):
settings = forms.CharField()
version = forms.ChoiceField(choices=[
("trunk", "trunk"),
("1.2", "1.2"),
("1.1.2",... |
from django import forms
from project.models import Project
class ProjectForm(forms.ModelForm):
class Meta:
model = Project
class DjangoRecipeForm(forms.Form):
name = forms.CharField(initial="django")
settings = forms.CharField()
version = forms.ChoiceField(choices=[
("trunk", "trunk... | Add a name for the recipe section | Add a name for the recipe section
| Python | apache-2.0 | pnomolos/greatbigcrane,pnomolos/greatbigcrane | python | ## Code Before:
from django import forms
from project.models import Project
class ProjectForm(forms.ModelForm):
class Meta:
model = Project
class DjangoRecipeForm(forms.Form):
settings = forms.CharField()
version = forms.ChoiceField(choices=[
("trunk", "trunk"),
("1.2", "1.2"),
... |
from django import forms
from project.models import Project
class ProjectForm(forms.ModelForm):
class Meta:
model = Project
class DjangoRecipeForm(forms.Form):
+ name = forms.CharField(initial="django")
settings = forms.CharField()
version = forms.ChoiceField(choices=... | 1 | 0.035714 | 1 | 0 |
86c3859838c93df1bbe90bce8abc9971f0affe1f | setup.py | setup.py | from setuptools import setup
setup(name='turtleart',
version='0.2',
description='Library to facilitate Turtle Art',
author='Ava and Teo Lisitza',
author_email='mlisitza+github@gmail.com',
packages=['turtleart', 'turtleart.scripts'],
entry_points={
'console_scripts': [
... | from setuptools import setup
setup(name='turtleart',
version='0.2',
description='Library to facilitate Turtle Art',
author='Ava and Teo Lisitza',
author_email='mlisitza+github@gmail.com',
packages=['turtleart', 'turtleart.scripts'],
entry_points={
'console_scripts': [
... | Make turtleart package require ipython | Make turtleart package require ipython
| Python | apache-2.0 | teolisitza/turtleart | python | ## Code Before:
from setuptools import setup
setup(name='turtleart',
version='0.2',
description='Library to facilitate Turtle Art',
author='Ava and Teo Lisitza',
author_email='mlisitza+github@gmail.com',
packages=['turtleart', 'turtleart.scripts'],
entry_points={
'console_... | from setuptools import setup
setup(name='turtleart',
version='0.2',
description='Library to facilitate Turtle Art',
author='Ava and Teo Lisitza',
author_email='mlisitza+github@gmail.com',
packages=['turtleart', 'turtleart.scripts'],
entry_points={
'cons... | 3 | 0.214286 | 3 | 0 |
550ce1de2a4c18b23cee724e2221db1a0da7f0db | src/command/suggest.cr | src/command/suggest.cr | module Command
command "suggest", "suggest someone to contact" do |_args, repository|
confirmed = Proc(String, Bool).new do |answer|
answer == "Y" || answer.empty?
end
contacts = repository.all.sort
suggested_contact = contacts.first
last_contact = suggested_contact.last_contacted
da... | module Command
command "suggest", "suggest someone to contact" do |_args, repository|
confirmed = Proc(String, Bool).new do |answer|
answer == "Y" || answer.empty?
end
contacts = repository.all.sort
suggested_contact = contacts.first
last_contact = suggested_contact.last_contacted
da... | Update contacted_at if message sent successfully | Update contacted_at if message sent successfully
| Crystal | mit | anicholson/barnabas | crystal | ## Code Before:
module Command
command "suggest", "suggest someone to contact" do |_args, repository|
confirmed = Proc(String, Bool).new do |answer|
answer == "Y" || answer.empty?
end
contacts = repository.all.sort
suggested_contact = contacts.first
last_contact = suggested_contact.last_c... | module Command
command "suggest", "suggest someone to contact" do |_args, repository|
confirmed = Proc(String, Bool).new do |answer|
answer == "Y" || answer.empty?
end
contacts = repository.all.sort
suggested_contact = contacts.first
last_contact = suggested_contact.... | 4 | 0.097561 | 3 | 1 |
fb2f66adf5ba60d2cda934ef27125ce84057367e | PCbuild/rmpyc.py | PCbuild/rmpyc.py |
def deltree(root):
import os
def rm(path):
os.unlink(path)
npyc = npyo = 0
dirs = [root]
while dirs:
dir = dirs.pop()
for short in os.listdir(dir):
full = os.path.join(dir, short)
if os.path.isdir(full):
dirs.append(full)
e... |
def deltree(root):
import os
from os.path import join
npyc = npyo = 0
for root, dirs, files in os.walk(root):
for name in files:
delete = False
if name.endswith('.pyc'):
delete = True
npyc += 1
elif name.endswith('.pyo'):
... | Use os.walk() to find files to delete. | Use os.walk() to find files to delete.
| Python | mit | sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator | python | ## Code Before:
def deltree(root):
import os
def rm(path):
os.unlink(path)
npyc = npyo = 0
dirs = [root]
while dirs:
dir = dirs.pop()
for short in os.listdir(dir):
full = os.path.join(dir, short)
if os.path.isdir(full):
dirs.append(ful... | +
def deltree(root):
import os
- def rm(path):
- os.unlink(path)
+ from os.path import join
+
npyc = npyo = 0
+ for root, dirs, files in os.walk(root):
+ for name in files:
+ delete = False
- dirs = [root]
- while dirs:
- dir = dirs.pop()
- ... | 27 | 1.173913 | 14 | 13 |
cce0d06150aea15d80af653c534725a44ff08cd6 | data/navigation.json | data/navigation.json | {
"header": {
"/cfp": {
"text": "Call for Proposals"
},
"/#speakers": {
"text": "Speakers",
"anchor": true
},
"/#venue": {
"text": "Venue",
"anchor": true
},
"/#sponsor": {
"text": "Sponso... | {
"header": {
"/cfp": {
"text": "Call for Proposals"
},
"/#speakers": {
"text": "Speakers",
"anchor": true
},
"/#venue": {
"text": "Venue",
"anchor": true
},
"/#sponsor": {
"text": "Sponso... | Remove schedule from header nav. | Remove schedule from header nav.
| JSON | mpl-2.0 | mdn/viewsourceconf,hoosteeno/viewsourceconf,hoosteeno/viewsourceconf,mdn/viewsourceconf,hoosteeno/viewsourceconf,mdn/viewsourceconf | json | ## Code Before:
{
"header": {
"/cfp": {
"text": "Call for Proposals"
},
"/#speakers": {
"text": "Speakers",
"anchor": true
},
"/#venue": {
"text": "Venue",
"anchor": true
},
"/#sponsor": {
... | {
"header": {
"/cfp": {
"text": "Call for Proposals"
},
"/#speakers": {
"text": "Speakers",
"anchor": true
},
"/#venue": {
"text": "Venue",
"anchor": true
},
"/#sponsor": {... | 3 | 0.069767 | 0 | 3 |
d4fd4c0e1435ae3d527be87fba745725c9e9df1b | shaq_overflow/app/controllers/votes_controller.rb | shaq_overflow/app/controllers/votes_controller.rb | class VotesController < ApplicationController
def create
if request.xhr?
vote = Vote.create(votable_type: params[:votableType], user_id: current_user.id, value: 1, votable_id: params[:answerId])
answer = Answer.find(params[:answerId])
votes = answer.votes.count
votes.to_json
render ... | class VotesController < ApplicationController
def create
if request.xhr?
if params[:direction] == "up"
vote = Vote.create(votable_type: params[:votableType], user_id: current_user.id, value: 1, votable_id: params[:answerId])
@answer = Answer.find(params[:answerId])
else
vote =... | Add conditional logic for up and down votes | Add conditional logic for up and down votes
| Ruby | mit | lucasrsantos1/lucky-ambassador,lucasrsantos1/lucky-ambassador,lucasrsantos1/lucky-ambassador | ruby | ## Code Before:
class VotesController < ApplicationController
def create
if request.xhr?
vote = Vote.create(votable_type: params[:votableType], user_id: current_user.id, value: 1, votable_id: params[:answerId])
answer = Answer.find(params[:answerId])
votes = answer.votes.count
votes.to_js... | class VotesController < ApplicationController
def create
if request.xhr?
+ if params[:direction] == "up"
- vote = Vote.create(votable_type: params[:votableType], user_id: current_user.id, value: 1, votable_id: params[:answerId])
+ vote = Vote.create(votable_type: params[:votableType],... | 17 | 1.307692 | 12 | 5 |
0076e9d9384fcce6e40b9c8f24ad57b986c5a68f | public/js/rss-reader.js | public/js/rss-reader.js | $(function() {
setInterval(function () {
$(".humantime").each(function () {
var $time = $(this);
$.get('/humantime', { stamp: this.dataset.stamp }, function(data) {
$time.text(data)
});
});
}, 90000);
});
| $(function() {
setInterval(function () {
$(".humantime").each(function () {
var $time = $(this);
$.get('/humantime', { stamp: this.dataset.stamp }, function(data) {
$time.text(data)
});
});
}, 90000);
$("select#feeds").on('change', functi... | Add change function for feed select | Add change function for feed select
| JavaScript | mit | JulianNicholls/ruby-rss-reader,JulianNicholls/ruby-rss-reader,JulianNicholls/ruby-rss-reader | javascript | ## Code Before:
$(function() {
setInterval(function () {
$(".humantime").each(function () {
var $time = $(this);
$.get('/humantime', { stamp: this.dataset.stamp }, function(data) {
$time.text(data)
});
});
}, 90000);
});
## Instruction:
Add c... | $(function() {
setInterval(function () {
$(".humantime").each(function () {
var $time = $(this);
$.get('/humantime', { stamp: this.dataset.stamp }, function(data) {
$time.text(data)
});
});
}, 90000);
+
+ $("select#fee... | 4 | 0.363636 | 4 | 0 |
5f3f4007b9ce06915ab3460019ac9dd4fe17a9ce | docs/source/tricks.rst | docs/source/tricks.rst | .. _chapter-tricks:
===================
Tips, Tricks & FAQs
===================
A collection of miscellanous tips, tricks and frequently asked
questions
Derivatives
===========
The single most important bit of advice for users of Ceres Solver is
to use analytic/automatic differentiation when you can. It is tempting... | .. _chapter-tricks:
===================
Tips, Tricks & FAQs
===================
A collection of miscellanous tips, tricks and answers to frequently
asked questions.
1. Use analytical/automatic derivatives when possible.
This is the single most important piece of advice we can give to
you. It is tempting to ta... | Extend the advice on derivatives. | Extend the advice on derivatives.
Extend the tips/tricks section to include more comprehensive
advice on derivatives.
Change-Id: Iba5768055b32a65e36d70e6f4db62eca9b331253
| reStructuredText | bsd-3-clause | ysonggit/ceres-solver,entylop/ceres-solver,timfel/ceres-bin,DougFirErickson/ceres-solver,timfel/ceres-bin,kartikkumar/ceres-solver,ikoruk/ceres-solver,kartikkumar/ceres-solver,stonier/ceres_solver,DougFirErickson/ceres-solver,ikoruk/ceres-solver,timfel/ceres-bin,kartikkumar/ceres-solver,ikoruk/ceres-solver,stonier/cere... | restructuredtext | ## Code Before:
.. _chapter-tricks:
===================
Tips, Tricks & FAQs
===================
A collection of miscellanous tips, tricks and frequently asked
questions
Derivatives
===========
The single most important bit of advice for users of Ceres Solver is
to use analytic/automatic differentiation when you can... | .. _chapter-tricks:
===================
Tips, Tricks & FAQs
===================
- A collection of miscellanous tips, tricks and frequently asked
? ------
+ A collection of miscellanous tips, tricks and answers to frequently
? ... | 47 | 2.764706 | 38 | 9 |
798f1ece02ee49b85b1b6a65d74f76e8b9938405 | packages/dh/dhall-lex.yaml | packages/dh/dhall-lex.yaml | homepage: ''
changelog-type: ''
hash: 8fcf55f0ccb76069b8441a1dada75f894eb04698858fb22e961dffff2442c480
test-bench-deps:
bytestring: -any
base: -any
hspec: -any
criterion: -any
dhall-lex: -any
hspec-dirstream: ! '>=1.0.0.0'
maintainer: vamchale@gmail.com
synopsis: Lexer for the Dhall language
changelog: ''
b... | homepage: ''
changelog-type: ''
hash: 4b9e298df794c3468ec43e53e96a4a90b725f8ce49d6336dee476c3fbb3dffe0
test-bench-deps:
bytestring: -any
base: -any
hspec: -any
criterion: -any
dhall-lex: -any
hspec-dirstream: ! '>=1.0.0.0'
maintainer: vamchale@gmail.com
synopsis: Lexer for the Dhall language
changelog: ''
b... | Update from Hackage at 2018-03-25T05:47:21Z | Update from Hackage at 2018-03-25T05:47:21Z
| YAML | mit | commercialhaskell/all-cabal-metadata | yaml | ## Code Before:
homepage: ''
changelog-type: ''
hash: 8fcf55f0ccb76069b8441a1dada75f894eb04698858fb22e961dffff2442c480
test-bench-deps:
bytestring: -any
base: -any
hspec: -any
criterion: -any
dhall-lex: -any
hspec-dirstream: ! '>=1.0.0.0'
maintainer: vamchale@gmail.com
synopsis: Lexer for the Dhall language... | homepage: ''
changelog-type: ''
- hash: 8fcf55f0ccb76069b8441a1dada75f894eb04698858fb22e961dffff2442c480
+ hash: 4b9e298df794c3468ec43e53e96a4a90b725f8ce49d6336dee476c3fbb3dffe0
test-bench-deps:
bytestring: -any
base: -any
hspec: -any
criterion: -any
dhall-lex: -any
hspec-dirstream: ! '>=1... | 5 | 0.15625 | 3 | 2 |
85ef77ab98a99e463eb17002e656d4f0dd4ef0b0 | app/products/products.tpl.html | app/products/products.tpl.html | <nav class="navbar navbar-default" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<a class="navbar-brand" href="#!/products">HUB GOURMET</a>
</div>
<div class="collapse navbar-collapse navbar-ex1-collapse">
<ul class="nav navbar-nav">
<li><a href="#!/produ... | <nav class="navbar navbar-default" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<a class="navbar-brand" href="#!/products">HUB GOURMET</a>
</div>
<div class="collapse navbar-collapse">
<ul class="nav navbar-nav">
<li><a href="#!/products">PRODUCTS</a></l... | Fix grid system in products view | Fix grid system in products view
| HTML | agpl-3.0 | stivaliserna/hub-gourmet-client,stivaliserna/hub-gourmet-client | html | ## Code Before:
<nav class="navbar navbar-default" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<a class="navbar-brand" href="#!/products">HUB GOURMET</a>
</div>
<div class="collapse navbar-collapse navbar-ex1-collapse">
<ul class="nav navbar-nav">
<li><... | <nav class="navbar navbar-default" role="navigation">
<div class="container-fluid">
<div class="navbar-header">
<a class="navbar-brand" href="#!/products">HUB GOURMET</a>
</div>
- <div class="collapse navbar-collapse navbar-ex1-collapse">
? ---------... | 4 | 0.129032 | 2 | 2 |
943a6c173c366dad1207b53d79b35e4f97ed0062 | src/server/handlers/badge.js | src/server/handlers/badge.js | import path from 'path';
import logging from '../logging';
const logger = logging.getLogger('express');
import {
internalFindSnap,
internalGetSnapBuilds
} from './launchpad';
import { getGitHubRepoUrl } from '../../common/helpers/github-url';
import { snapBuildFromAPI } from '../../common/helpers/snap-builds';
c... | import path from 'path';
import logging from '../logging';
const logger = logging.getLogger('express');
import {
internalFindSnap,
internalGetSnapBuilds
} from './launchpad';
import { getGitHubRepoUrl } from '../../common/helpers/github-url';
import { snapBuildFromAPI } from '../../common/helpers/snap-builds';
c... | Add Extra Cache Headers To Build Badge Response | Add Extra Cache Headers To Build Badge Response
Add extra cache prevention headers to the build badge response. This should help
reduce caching on GitHub README's. | JavaScript | agpl-3.0 | canonical-ols/build.snapcraft.io,canonical-ols/build.snapcraft.io,canonical-ols/build.snapcraft.io | javascript | ## Code Before:
import path from 'path';
import logging from '../logging';
const logger = logging.getLogger('express');
import {
internalFindSnap,
internalGetSnapBuilds
} from './launchpad';
import { getGitHubRepoUrl } from '../../common/helpers/github-url';
import { snapBuildFromAPI } from '../../common/helpers/... | import path from 'path';
import logging from '../logging';
const logger = logging.getLogger('express');
import {
internalFindSnap,
internalGetSnapBuilds
} from './launchpad';
import { getGitHubRepoUrl } from '../../common/helpers/github-url';
import { snapBuildFromAPI } from '../../common/he... | 4 | 0.1 | 3 | 1 |
1aee2e232edb2bdeeda563a612b1ba3f6a33b09a | undercloud/install.sh | undercloud/install.sh | set -eux
set -o pipefail
if [[ $USER != "stack" ]]; then
echo "Must be run as stack user.";
exit 1;
fi
sudo yum upgrade -y;
sudo yum install -y ack vim libffi-devel libssl-devel openssl-devel python-devel;
rm -rf ~/tripleo-ci
git clone https://github.com/openstack-infra/tripleo-ci.git ~/tripleo-ci
~/tripleo-ci/s... | set -eux
set -o pipefail
if [[ $USER != "stack" ]]; then
echo "Must be run as stack user.";
exit 1;
fi
sudo yum upgrade -y;
sudo yum install -y ack vim libffi-devel libssl-devel openssl-devel python-devel;
rm -rf ~/tripleo-ci
git clone https://github.com/openstack-infra/tripleo-ci.git ~/tripleo-ci
~/tripleo-ci/s... | Update the location of the post update | Update the location of the post update
| Shell | bsd-2-clause | d0ugal/tripleo-util,d0ugal/tripleo-util | shell | ## Code Before:
set -eux
set -o pipefail
if [[ $USER != "stack" ]]; then
echo "Must be run as stack user.";
exit 1;
fi
sudo yum upgrade -y;
sudo yum install -y ack vim libffi-devel libssl-devel openssl-devel python-devel;
rm -rf ~/tripleo-ci
git clone https://github.com/openstack-infra/tripleo-ci.git ~/tripleo-ci... | set -eux
set -o pipefail
if [[ $USER != "stack" ]]; then
echo "Must be run as stack user.";
exit 1;
fi
sudo yum upgrade -y;
sudo yum install -y ack vim libffi-devel libssl-devel openssl-devel python-devel;
rm -rf ~/tripleo-ci
git clone https://github.com/openstack-infra/tripleo-ci.git ~/... | 2 | 0.057143 | 1 | 1 |
d72e19200de282072fecc4393031104f4b96793f | src/index.js | src/index.js | import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import { createStore } from 'redux';
import App from './components/app';
import reducers from './redux/reducers';
ReactDOM.render(
<Provider store={createStore(reducers)}>
<App />
</Provider>,
docu... | import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import { createStore, compose } from 'redux';
import App from './components/app';
import reducers from './redux/reducers';
const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose;
ReactDOM.r... | Add redux dev tool support | Add redux dev tool support
| JavaScript | mit | JPStrydom/Sudoku-AI,JPStrydom/Sudoku-AI | javascript | ## Code Before:
import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import { createStore } from 'redux';
import App from './components/app';
import reducers from './redux/reducers';
ReactDOM.render(
<Provider store={createStore(reducers)}>
<App />
</Pro... | import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
- import { createStore } from 'redux';
+ import { createStore, compose } from 'redux';
? +++++++++
+
import App from './components/app';
import reducers from './redux/reducers';
+
... | 8 | 0.571429 | 6 | 2 |
dc4be3b4e6ba136fd4d2283d997051a2400a089e | pakyow-core/lib/core/helpers.rb | pakyow-core/lib/core/helpers.rb | module Pakyow
# Helpers available anywhere
#
# @api public
module Helpers
def context
@context or raise NoContextError
end
def logger
request.logger
end
def router
RouteLookup.new
end
def request
context ? context.request : nil
end
alias_method :req... | module Pakyow
# Helpers available anywhere
#
# @api public
module Helpers
def context
@context or raise NoContextError
end
def logger
request.logger || Pakyow.logger
end
def router
RouteLookup.new
end
def request
context ? context.request : nil
end
... | Use Pakyow.logger if req.logger isn't available | Use Pakyow.logger if req.logger isn't available
The logger won’t be available on the request if the logging middleware
isn’t enabled.
| Ruby | mit | jphager2/pakyow,karimmtarek/pakyow,karimmtarek/pakyow,karimmtarek/pakyow,jphager2/pakyow,jphager2/pakyow | ruby | ## Code Before:
module Pakyow
# Helpers available anywhere
#
# @api public
module Helpers
def context
@context or raise NoContextError
end
def logger
request.logger
end
def router
RouteLookup.new
end
def request
context ? context.request : nil
end
a... | module Pakyow
# Helpers available anywhere
#
# @api public
module Helpers
def context
@context or raise NoContextError
end
def logger
- request.logger
+ request.logger || Pakyow.logger
end
def router
RouteLookup.new
end
def... | 2 | 0.032787 | 1 | 1 |
c5dfcd45b1a9fa5aad8f9718d3784af45e88920d | plugins/bwana/README.md | plugins/bwana/README.md |
This plugin provides a function to open `man` pages directly with [Bwana](https://www.bruji.com/bwana/).
To use it add bwana to the plugins array in your zshrc file.
```bash
plugins=(... bwana)
```
## Functions
| Function | Description |
| -------- | -----------------------------------... |
This plugin provides a function to open `man` pages directly with [Bwana](https://www.bruji.com/bwana/).
To use it add bwana to the plugins array in your zshrc file.
```bash
plugins=(... bwana)
```
The `bwana` function opens the man page of the passed argument in the Bwana app.
For example: `bwana ln` opens the man... | Simplify explanation of bwana function | Simplify explanation of bwana function | Markdown | mit | tekniklr/oh-my-zsh,tekniklr/oh-my-zsh | markdown | ## Code Before:
This plugin provides a function to open `man` pages directly with [Bwana](https://www.bruji.com/bwana/).
To use it add bwana to the plugins array in your zshrc file.
```bash
plugins=(... bwana)
```
## Functions
| Function | Description |
| -------- | -------------------... |
This plugin provides a function to open `man` pages directly with [Bwana](https://www.bruji.com/bwana/).
To use it add bwana to the plugins array in your zshrc file.
```bash
plugins=(... bwana)
```
+ The `bwana` function opens the man page of the passed argument in the Bwana app.
+ For example: `b... | 7 | 0.5 | 2 | 5 |
2ffd701a4ef3a86ee6168eea22d7c1c298b2bc1b | README.md | README.md | Boogie
======
Git Pulling LibGDX-based pretty Application launcher
<a href="http://i.imgur.com/lq4dXtc.png"><img src="http://i.imgur.com/lq4dXtc.png" width="33%"></a><a href="http://i.imgur.com/0YomHoH.png"><img src="http://i.imgur.com/0YomHoH.png" width="33%"></a><a href="http://i.imgur.com/UfipTj6.png"><img src="ht... | Boogie
======
Git Pulling LibGDX-based pretty Application launcher. [Learn more from the Wiki](https://github.com/nhydock/Boogie/wiki)
<a href="http://i.imgur.com/lq4dXtc.png"><img src="http://i.imgur.com/lq4dXtc.png" width="33%"></a><a href="http://i.imgur.com/0YomHoH.png"><img src="http://i.imgur.com/0YomHoH.png" ... | Add link to wiki to purposely direct people | Add link to wiki to purposely direct people | Markdown | apache-2.0 | nhydock/Boogie | markdown | ## Code Before:
Boogie
======
Git Pulling LibGDX-based pretty Application launcher
<a href="http://i.imgur.com/lq4dXtc.png"><img src="http://i.imgur.com/lq4dXtc.png" width="33%"></a><a href="http://i.imgur.com/0YomHoH.png"><img src="http://i.imgur.com/0YomHoH.png" width="33%"></a><a href="http://i.imgur.com/UfipTj6.p... | Boogie
======
- Git Pulling LibGDX-based pretty Application launcher
+ Git Pulling LibGDX-based pretty Application launcher. [Learn more from the Wiki](https://github.com/nhydock/Boogie/wiki)
<a href="http://i.imgur.com/lq4dXtc.png"><img src="http://i.imgur.com/lq4dXtc.png" width="33%"></a><a href="http://... | 2 | 0.333333 | 1 | 1 |
2358f2ac14aa76ed8c8f54085e143fcbf3b99eb3 | db/migrate/20140217140257_add_state_to_documents_and_photos.rb | db/migrate/20140217140257_add_state_to_documents_and_photos.rb | class AddStateToDocumentsAndPhotos < ActiveRecord::Migration
def change
add_column :documents, :state, :string, :default => 'initialized'
add_column :photos, :state, :string, :default => 'initialized'
end
end
| class AddStateToDocumentsAndPhotos < ActiveRecord::Migration
def up
add_column :documents, :state, :string, :default => 'initialized'
add_column :photos, :state, :string, :default => 'initialized'
# set proper state for photos and documents
Document.update_all({state: 'uploaded'}, 'file IS NOT NUL... | Modify migration to set proper state for photos and documents | Modify migration to set proper state for photos and documents | Ruby | bsd-3-clause | netkodo/otwartezabytki,netkodo/otwartezabytki,netkodo/otwartezabytki,netkodo/otwartezabytki | ruby | ## Code Before:
class AddStateToDocumentsAndPhotos < ActiveRecord::Migration
def change
add_column :documents, :state, :string, :default => 'initialized'
add_column :photos, :state, :string, :default => 'initialized'
end
end
## Instruction:
Modify migration to set proper state for photos and documents
#... | class AddStateToDocumentsAndPhotos < ActiveRecord::Migration
- def change
+ def up
add_column :documents, :state, :string, :default => 'initialized'
add_column :photos, :state, :string, :default => 'initialized'
+
+ # set proper state for photos and documents
+ Document.update_all({state: ... | 14 | 2.333333 | 13 | 1 |
69e3ea7dcd550462519a9db472b8f6b96de9e9ac | db/migrate/20151014161021_sets_visual_checks_for_pico.rb | db/migrate/20151014161021_sets_visual_checks_for_pico.rb | class SetsVisualChecksForPico < ActiveRecord::Migration
def self.up
ActiveRecord::Base.transaction do
[*InstrumentProcess.find_by_name("Pico dilution")].each do |ip|
ip.update_attributes({
:visual_check_required => true
})
end
[*InstrumentProcess.find_by_name("Pico assay pl... | class SetsVisualChecksForPico < ActiveRecord::Migration
def self.up
ActiveRecord::Base.transaction do
[*InstrumentProcess.find_by_key("slf_pico_dilution")].each do |ip|
ip.update_attributes({
:visual_check_required => true
})
end
[*InstrumentProcess.find_by_key("slf_pico_as... | Update by key, instead of name, that is not compatible between environments (uat,nr,prod,...) | Update by key, instead of name, that is not compatible
between environments (uat,nr,prod,...)
| Ruby | mit | JamesGlover/asset_audits,JamesGlover/asset_audits,emrojo/asset_audits,sanger/asset_audits,JamesGlover/asset_audits,emrojo/asset_audits,JamesGlover/asset_audits,emrojo/asset_audits,sanger/asset_audits,sanger/asset_audits,sanger/asset_audits,emrojo/asset_audits | ruby | ## Code Before:
class SetsVisualChecksForPico < ActiveRecord::Migration
def self.up
ActiveRecord::Base.transaction do
[*InstrumentProcess.find_by_name("Pico dilution")].each do |ip|
ip.update_attributes({
:visual_check_required => true
})
end
[*InstrumentProcess.find_by_nam... | class SetsVisualChecksForPico < ActiveRecord::Migration
def self.up
ActiveRecord::Base.transaction do
- [*InstrumentProcess.find_by_name("Pico dilution")].each do |ip|
? ^^^ ^ ^
+ [*InstrumentProcess.find_by_key("slf_pico_dilution")].each do |ip|
? ... | 4 | 0.190476 | 2 | 2 |
cb74629334b4e6dadd3dec9b1a2e2fb5dddc9144 | res/raw/general_info.json | res/raw/general_info.json | {
"Opening hours": "<p>The festival site is accessible like this.</p>",
"First aid": "<p>Where to go if help if you need a medic.</p>",
"Infostand": "<p>Where you can find the infostand</p>",
"Tickets": "<h2>Ticket prices</h2><p><strong>Premium ticket price</strong> <br /><strong>Economy ticket price<br... | {
"Opening hours": "<p>The festival site is accessible like this.</p>",
"First aid": "<p>Where to go if help if you need a medic.</p>",
"Info stand": "<p>Where you can find the infostand</p>",
"Ticket sales": "<h2>Test prices</h2><p><strong>Premium test price</strong> <br /><strong>Economy ticket price<... | Fix missing content in Info view | Fix missing content in Info view
Because the contents of general_info.json is stored in the database, a
reinstall or upgrade is required to update database entries. Fixes issue #44.
| JSON | mit | futurice/festapp-android | json | ## Code Before:
{
"Opening hours": "<p>The festival site is accessible like this.</p>",
"First aid": "<p>Where to go if help if you need a medic.</p>",
"Infostand": "<p>Where you can find the infostand</p>",
"Tickets": "<h2>Ticket prices</h2><p><strong>Premium ticket price</strong> <br /><strong>Economy... | {
"Opening hours": "<p>The festival site is accessible like this.</p>",
"First aid": "<p>Where to go if help if you need a medic.</p>",
- "Infostand": "<p>Where you can find the infostand</p>",
+ "Info stand": "<p>Where you can find the infostand</p>",
? +
- "Tickets": "<h2>Ticket pr... | 7 | 0.875 | 4 | 3 |
642b131817043af4a378340bb2ae4949c9e45865 | src/SfVlc/MainBundle/Mailer/Mailer.php | src/SfVlc/MainBundle/Mailer/Mailer.php | <?php
namespace SfVlc\MainBundle\Mailer;
use SfVlc\MainBundle\Form\Model\Contact;
use SfVlc\MainBundle\Mailer\ContactConfigurationInterface;
class Mailer
{
protected $mailer;
protected $settings;
function __construct($mailer, ContactConfigurationInterface $settings)
{
$this->mailer = $mailer;
$this->setting... | <?php
namespace SfVlc\MainBundle\Mailer;
use SfVlc\MainBundle\Form\Model\Contact;
use SfVlc\MainBundle\Mailer\ContactConfigurationInterface;
class Mailer
{
protected $mailer;
protected $settings;
function __construct(\Swift_Mailer $mailer, ContactConfigurationInterface $settings)
{
$this->mailer = $mailer;
... | Add type of mailer in contructor | Add type of mailer in contructor
| PHP | mit | symfonyvlc/symfonyvalencia | php | ## Code Before:
<?php
namespace SfVlc\MainBundle\Mailer;
use SfVlc\MainBundle\Form\Model\Contact;
use SfVlc\MainBundle\Mailer\ContactConfigurationInterface;
class Mailer
{
protected $mailer;
protected $settings;
function __construct($mailer, ContactConfigurationInterface $settings)
{
$this->mailer = $mailer;
... | <?php
namespace SfVlc\MainBundle\Mailer;
use SfVlc\MainBundle\Form\Model\Contact;
use SfVlc\MainBundle\Mailer\ContactConfigurationInterface;
class Mailer
{
protected $mailer;
protected $settings;
- function __construct($mailer, ContactConfigurationInterface $settings)
+ function __constr... | 2 | 0.066667 | 1 | 1 |
f503d0a877821e37c7b3d5bf6527bc327da69737 | src/CMakeLists.txt | src/CMakeLists.txt | set(SOURCES
main.cpp
Font.cpp
maxRectsBinPack/MaxRectsBinPack.cpp
sdlSavePng/savepng.c
tinyxml2/tinyxml2.cpp
ConfigFile.cpp
CharList.cpp
)
if(MINGW)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
SET(MINGW32_LIBRARY mingw32 CACHE STRING "mwindows for MinGW")
FIND_LIBRARY(SDL2MAIN_LIBRARY NAMES SD... | set(SOURCES
main.cpp
Font.cpp
maxRectsBinPack/MaxRectsBinPack.cpp
sdlSavePng/savepng.c
tinyxml2/tinyxml2.cpp
ConfigFile.cpp
CharList.cpp
)
if(MINGW)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
SET(MINGW32_LIBRARY mingw32 CACHE STRING "mwindows for MinGW")
FIND_LIBRARY(SDL2MAIN_LIBRARY NAMES SD... | Add SDL2main lib to link | Add SDL2main lib to link
| Text | mit | vladimirgamalian/fontbm,vladimirgamalian/fontbm,vladimirgamalian/fontbm | text | ## Code Before:
set(SOURCES
main.cpp
Font.cpp
maxRectsBinPack/MaxRectsBinPack.cpp
sdlSavePng/savepng.c
tinyxml2/tinyxml2.cpp
ConfigFile.cpp
CharList.cpp
)
if(MINGW)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
SET(MINGW32_LIBRARY mingw32 CACHE STRING "mwindows for MinGW")
FIND_LIBRARY(SDL2MAIN_... | set(SOURCES
main.cpp
Font.cpp
maxRectsBinPack/MaxRectsBinPack.cpp
sdlSavePng/savepng.c
tinyxml2/tinyxml2.cpp
ConfigFile.cpp
CharList.cpp
)
if(MINGW)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
SET(MINGW32_LIBRARY mingw32 CACHE STRING "mwindows for MinGW")
FIND_LIBRA... | 5 | 0.263158 | 5 | 0 |
61be745b641689addc9f009311d28a5775d5a18b | ctconfig.py | ctconfig.py | import logging
import json
from tornado.options import define, options
_CONFIG_FILENAME = "cutthroat.conf"
def define_options():
"""Define defaults for most custom options"""
# Log file and config file paths
options.log_file_prefix = "/var/log/cutthroat/cutthroat.log"
define(
"conf_file_path... | import logging
import json
from tornado.options import define, options
_CONFIG_FILENAME = "cutthroat.conf"
def define_options():
"""Define defaults for most custom options"""
# Log file and config file paths
options.log_file_prefix = "/var/log/cutthroat/cutthroat.log"
define(
"conf_file_path... | Set `output_routes` to True by default | Set `output_routes` to True by default | Python | agpl-3.0 | hfaran/LivesPool,hfaran/LivesPool,hfaran/LivesPool,hfaran/LivesPool | python | ## Code Before:
import logging
import json
from tornado.options import define, options
_CONFIG_FILENAME = "cutthroat.conf"
def define_options():
"""Define defaults for most custom options"""
# Log file and config file paths
options.log_file_prefix = "/var/log/cutthroat/cutthroat.log"
define(
... | import logging
import json
from tornado.options import define, options
_CONFIG_FILENAME = "cutthroat.conf"
def define_options():
"""Define defaults for most custom options"""
# Log file and config file paths
options.log_file_prefix = "/var/log/cutthroat/cutthroat.log"
defin... | 3 | 0.075 | 1 | 2 |
e24a9da1b580f24ea7bbf373e8bdb832cafc26d0 | src/allejo/stakx/app/services.yml | src/allejo/stakx/app/services.yml | services:
_defaults:
autowire: true
autoconfigure: true
public: true
allejo\stakx\Manager\:
resource: '../Manager/*'
calls:
- { method: 'setLogger', arguments: ['@logger'] }
allejo\stakx\Manager\ThemeManager:
arguments:
- null
output:
class: Symfony\Component\Console\O... | services:
_defaults:
autowire: true
autoconfigure: true
public: true
allejo\stakx\Manager\:
resource: '../Manager/*'
calls:
- { method: 'setLogger', arguments: ['@logger'] }
- { method: 'setContainer', arguments: ['@service_container'] }
allejo\stakx\Manager\ThemeManager:
arg... | Add container to manager classes | Add container to manager classes
| YAML | mit | stakx-io/stakx,allejo/stakx,allejo/stakx,stakx-io/stakx | yaml | ## Code Before:
services:
_defaults:
autowire: true
autoconfigure: true
public: true
allejo\stakx\Manager\:
resource: '../Manager/*'
calls:
- { method: 'setLogger', arguments: ['@logger'] }
allejo\stakx\Manager\ThemeManager:
arguments:
- null
output:
class: Symfony\Com... | services:
_defaults:
autowire: true
autoconfigure: true
public: true
allejo\stakx\Manager\:
resource: '../Manager/*'
calls:
- { method: 'setLogger', arguments: ['@logger'] }
+ - { method: 'setContainer', arguments: ['@service_container'] }
allejo\stakx\Man... | 1 | 0.045455 | 1 | 0 |
b022636e2ba92ba24c738759bbfc1afd408f8a5b | docs/index.markdown | docs/index.markdown | ---
layout: docs
title: Quarks Documentation
description: Documentation project for Quarks
---
# Quarks Documentation
Documentation for Quarks Project
# Table of Content
{% include nav.html context="/docs/"%}
# New Documentation
To request new documentation, please open an issue here:
<form action="{{site.do... | ---
layout: docs
title: Quarks Documentation
description: Documentation project for Quarks
---
# Quarks Documentation
Documentation for Quarks Project
# Table of Contents
{% include nav.html context="/docs/"%}
# New Documentation
Quarks is evolving, and so is the documentation. If the existing documentation hasn't... | Enhance New Documentation section to ensure that the purpose is clear. | Enhance New Documentation section to ensure that the purpose is clear.
| Markdown | apache-2.0 | quarks-edge/quarks.documentation,quarks-edge/quarks.documentation,quarks-edge/quarks.documentation,quarks-edge/quarks.documentation | markdown | ## Code Before:
---
layout: docs
title: Quarks Documentation
description: Documentation project for Quarks
---
# Quarks Documentation
Documentation for Quarks Project
# Table of Content
{% include nav.html context="/docs/"%}
# New Documentation
To request new documentation, please open an issue here:
<form a... | ---
layout: docs
title: Quarks Documentation
description: Documentation project for Quarks
---
# Quarks Documentation
-
Documentation for Quarks Project
- # Table of Content
+ # Table of Contents
? +
{% include nav.html context="/docs/"%}
# New Documentation
+ Quarks is ... | 8 | 0.190476 | 4 | 4 |
e746218ba8915ee395e178e7e30dcbbdda4dfc50 | types/react-router/test/WithRouter.tsx | types/react-router/test/WithRouter.tsx | import * as React from 'react';
import { withRouter, RouteComponentProps } from 'react-router-dom';
interface TOwnProps extends RouteComponentProps {
username: string;
}
const ComponentFunction = (props: TOwnProps) => (
<h2>Welcome {props.username}</h2>
);
class ComponentClass extends React.Component<TOwnPro... | import * as React from 'react';
import { withRouter, RouteComponentProps } from 'react-router-dom';
interface TOwnProps extends RouteComponentProps {
username: string;
}
const ComponentFunction = (props: TOwnProps) => (
<h2>Welcome {props.username}</h2>
);
class ComponentClass extends React.Component<TOwnPro... | Add failing test for union props | [react-router] Add failing test for union props
| TypeScript | mit | georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/DefinitelyTyped,borisyankov/DefinitelyTyped,dsebastien/DefinitelyTyped,markogresak/DefinitelyTyped,dsebastien/DefinitelyTyped,borisyankov/DefinitelyTyped,mcliment/DefinitelyTyped | typescript | ## Code Before:
import * as React from 'react';
import { withRouter, RouteComponentProps } from 'react-router-dom';
interface TOwnProps extends RouteComponentProps {
username: string;
}
const ComponentFunction = (props: TOwnProps) => (
<h2>Welcome {props.username}</h2>
);
class ComponentClass extends React.C... | import * as React from 'react';
import { withRouter, RouteComponentProps } from 'react-router-dom';
interface TOwnProps extends RouteComponentProps {
username: string;
}
const ComponentFunction = (props: TOwnProps) => (
<h2>Welcome {props.username}</h2>
);
class ComponentClass extends... | 28 | 1.166667 | 28 | 0 |
526c25828ba712b0f25cf3d069d9d56fe568cbf3 | docs/docs/dev/virtlet-ci.md | docs/docs/dev/virtlet-ci.md | The details of CircleCI setup
Using CircleCI with your fork of Virtlet
|
Virtlet uses [CircleCI](https://circleci.com/) for building binaries,
docker images and running the tests. The CI configuration resides in
[.circleci/config.yml](https://github.com/Mirantis/virtlet/blob/master/.circleci/config.yml)
file. You can sign into CircleCI, and make it run tests for your own
fork of Virtlet by... | Add proper Virtlet CI docs | Add proper Virtlet CI docs
| Markdown | apache-2.0 | Mirantis/virtlet,Mirantis/virtlet | markdown | ## Code Before:
The details of CircleCI setup
Using CircleCI with your fork of Virtlet
## Instruction:
Add proper Virtlet CI docs
## Code After:
Virtlet uses [CircleCI](https://circleci.com/) for building binaries,
docker images and running the tests. The CI configuration resides in
[.circleci/config.yml](https://g... | - The details of CircleCI setup
- Using CircleCI with your fork of Virtlet
+ Virtlet uses [CircleCI](https://circleci.com/) for building binaries,
+ docker images and running the tests. The CI configuration resides in
+ [.circleci/config.yml](https://github.com/Mirantis/virtlet/blob/master/.circleci/config.yml)
+ fi... | 17 | 5.666667 | 15 | 2 |
8da89aacf70d89f0f6ecdaff38ab91cbe4c64b6f | app/static/js/global.js | app/static/js/global.js | if(document.getElementById("resume") !== null) {
PDFObject.embed("/static/gen/resume.pdf", "#resume");
}
| if(document.getElementById("resume") !== null) {
$(() => {
PDFObject.embed("/static/gen/resume.pdf", "#resume");
});
}
| Make sure pdf is loaded at the correct time | Make sure pdf is loaded at the correct time
| JavaScript | mit | albertyw/albertyw.com,albertyw/albertyw.com,albertyw/albertyw.com,albertyw/albertyw.com,albertyw/albertyw.com | javascript | ## Code Before:
if(document.getElementById("resume") !== null) {
PDFObject.embed("/static/gen/resume.pdf", "#resume");
}
## Instruction:
Make sure pdf is loaded at the correct time
## Code After:
if(document.getElementById("resume") !== null) {
$(() => {
PDFObject.embed("/static/gen/resume.pdf", "#resume");
... | if(document.getElementById("resume") !== null) {
+ $(() => {
- PDFObject.embed("/static/gen/resume.pdf", "#resume");
+ PDFObject.embed("/static/gen/resume.pdf", "#resume");
? ++
+ });
} | 4 | 1.333333 | 3 | 1 |
fb11a6a3b4e13b16c537217e7e698467054febcc | mobile/src/main/java/com/stefanhoth/ropasclisp/achievements/AchievementObserver.java | mobile/src/main/java/com/stefanhoth/ropasclisp/achievements/AchievementObserver.java | package com.stefanhoth.ropasclisp.achievements;
import com.stefanhoth.ropasclisp.games_sdk.PlayGamesClient;
public class AchievementObserver {
private final PlayGamesClient playGamesClient;
private final boolean firstSessionToday;
public AchievementObserver(PlayGamesClient playGamesClient, boolean first... | package com.stefanhoth.ropasclisp.achievements;
import android.content.Context;
import com.stefanhoth.ropasclisp.games_sdk.PlayGamesClient;
public class AchievementObserver {
private final PlayGamesClient playGamesClient;
private final Context context;
public AchievementObserver(PlayGamesClient playGam... | Correct behavior for daily start awards | Correct behavior for daily start awards
| Java | mit | stefanhoth/ropasclisp | java | ## Code Before:
package com.stefanhoth.ropasclisp.achievements;
import com.stefanhoth.ropasclisp.games_sdk.PlayGamesClient;
public class AchievementObserver {
private final PlayGamesClient playGamesClient;
private final boolean firstSessionToday;
public AchievementObserver(PlayGamesClient playGamesClien... | package com.stefanhoth.ropasclisp.achievements;
+
+ import android.content.Context;
import com.stefanhoth.ropasclisp.games_sdk.PlayGamesClient;
public class AchievementObserver {
private final PlayGamesClient playGamesClient;
- private final boolean firstSessionToday;
+ private final Conte... | 23 | 0.741935 | 17 | 6 |
ce1dc7e9785d33676edf0d44a83456eae7af0831 | README.md | README.md | Dependency Injection with Ninject
=================================
This is a simple lunch presentation to demonstrate some common scenarios of using
dependency injection with Ninject.
Exercise 1
----------
Tightly coupled code, no IoC used.
Exercise 2
----------
Added in manual dependency injection.
Exercise 3
--... | Dependency Injection with Ninject
=================================
NOTE
----
This presentation is probably out of date but may still be useful for basic examples.
This is a simple lunch presentation to demonstrate some common scenarios of using
dependency injection with Ninject.
Exercise 1
----------
Tightly coupl... | Add out of date warning | Add out of date warning | Markdown | mit | paulzerkel/di-ninject,paulzerkel/di-ninject,paulzerkel/di-ninject | markdown | ## Code Before:
Dependency Injection with Ninject
=================================
This is a simple lunch presentation to demonstrate some common scenarios of using
dependency injection with Ninject.
Exercise 1
----------
Tightly coupled code, no IoC used.
Exercise 2
----------
Added in manual dependency injection... | Dependency Injection with Ninject
=================================
+
+ NOTE
+ ----
+ This presentation is probably out of date but may still be useful for basic examples.
This is a simple lunch presentation to demonstrate some common scenarios of using
dependency injection with Ninject.
Exercise 1
... | 4 | 0.16 | 4 | 0 |
1a6015e73fbbfef228b0aa91827a0ad2da3deba0 | vm/vm_internal.h | vm/vm_internal.h |
typedef struct {
vm_value reg[num_regs];
int return_address;
int result_register;
//TODO type for this should be heap_address
int spilled_arguments; // Used for over-saturated calls.
} stack_frame ;
typedef struct {
stack_frame stack[stack_size];
int stack_pointer;
int program_pointer;
vm_value... |
typedef struct {
vm_value reg[num_regs];
int return_address;
int result_register;
heap_address spilled_arguments; // Used for over-saturated calls.
} stack_frame ;
typedef struct {
stack_frame stack[stack_size];
int stack_pointer;
int program_pointer;
vm_value *const_table;
int const_table_leng... | Fix type for spilled arguments | Fix type for spilled arguments
| C | mit | arne-schroppe/dash,arne-schroppe/dash | c | ## Code Before:
typedef struct {
vm_value reg[num_regs];
int return_address;
int result_register;
//TODO type for this should be heap_address
int spilled_arguments; // Used for over-saturated calls.
} stack_frame ;
typedef struct {
stack_frame stack[stack_size];
int stack_pointer;
int program_poi... |
typedef struct {
vm_value reg[num_regs];
int return_address;
int result_register;
- //TODO type for this should be heap_address
- int spilled_arguments; // Used for over-saturated calls.
? ^^^
+ heap_address spilled_arguments; // Used for over-saturated calls.
? ^^^^^^^^^^^^
} stack... | 3 | 0.090909 | 1 | 2 |
d703396e3cafea68bee55f95ad91e8a0c9b0b6b3 | .travis.yml | .travis.yml | language: python
python:
- "2.6"
- "2.7"
- "3.3"
- "3.4"
install:
- "pip install -r requirements.txt"
- "pip install -r test-requirements.txt"
script:
- tox -e pep8
- tox
| language: python
python:
- "2.7"
- "3.3"
- "3.4"
- "3.5"
before_script:
- eval "$(gimme 1.6)"
- mkdir $HOME/go
- export GOPATH="$HOME/go"
- export PATH="$PATH:$GOPATH/bin"
- echo $GOPATH
- echo $PATH
- go get -d github.com/ipfs/go-ipfs
- pushd . && cd $GOPATH/src/github.com/ipfs/go-ipfs && make ... | Fix TravisCI to run functional tests. | Fix TravisCI to run functional tests.
TravisCI now installs the latest version of IPFS
and runs the daemon before starting the testing
suite. This means that the functional tests can
now pass, whereas before they "failed to connect"
to a non-running daemon. Unfortunately, TravisCI
will "go get" IPFS, which gives us no... | YAML | mit | alexander255/py-ipfs-api,ipfs/py-ipfs-api,ipfs/python-ipfs-api,ipfs/py-ipfs-api,alexander255/py-ipfs-api | yaml | ## Code Before:
language: python
python:
- "2.6"
- "2.7"
- "3.3"
- "3.4"
install:
- "pip install -r requirements.txt"
- "pip install -r test-requirements.txt"
script:
- tox -e pep8
- tox
## Instruction:
Fix TravisCI to run functional tests.
TravisCI now installs the latest version of IPFS
and runs the... | language: python
python:
- - "2.6"
- "2.7"
- "3.3"
- "3.4"
+ - "3.5"
+ before_script:
+ - eval "$(gimme 1.6)"
+ - mkdir $HOME/go
+ - export GOPATH="$HOME/go"
+ - export PATH="$PATH:$GOPATH/bin"
+ - echo $GOPATH
+ - echo $PATH
+ - go get -d github.com/ipfs/go-ipfs
+ - pushd . && cd $G... | 13 | 1.083333 | 12 | 1 |
83d4f75727fa5fc486b571072b4e6061415ebdce | packages/google-trends-map/package.js | packages/google-trends-map/package.js | Package.describe({
name: 'google-trends-map',
version: '0.0.1',
summary: '',
});
//
Package.onUse(function(api) {
api.versionsFrom('1.0.4.2');
api.use(['imon-data']);
api.use(['mongo', 'widget', 'momentjs:moment', 'underscore',
'country-info', 'aldeed:collection2']);
api.use(['http'], 'server'... | Package.describe({
name: 'google-trends-map',
version: '0.0.1',
summary: '',
});
//
Package.onUse(function(api) {
api.versionsFrom('1.0.4.2');
api.use(['imon-data']);
api.use(['mongo', 'widget', 'momentjs:moment', 'underscore',
'country-info', 'aldeed:collection2']);
api.use(['http'], 'server'... | Fix npm request dependency issue in google-trends | Fix npm request dependency issue in google-trends
| JavaScript | mit | berkmancenter/internet_dashboard,berkmancenter/internet_dashboard,berkmancenter/internet_dashboard | javascript | ## Code Before:
Package.describe({
name: 'google-trends-map',
version: '0.0.1',
summary: '',
});
//
Package.onUse(function(api) {
api.versionsFrom('1.0.4.2');
api.use(['imon-data']);
api.use(['mongo', 'widget', 'momentjs:moment', 'underscore',
'country-info', 'aldeed:collection2']);
api.use(['... | Package.describe({
name: 'google-trends-map',
version: '0.0.1',
summary: '',
});
//
Package.onUse(function(api) {
api.versionsFrom('1.0.4.2');
api.use(['imon-data']);
api.use(['mongo', 'widget', 'momentjs:moment', 'underscore',
'country-info', 'aldeed:collection2']);
... | 2 | 0.074074 | 2 | 0 |
19ac2442de6c725c7bc45fcd69cc62fe7b5a24cb | app/models/manageiq/providers/embedded_automation_manager.rb | app/models/manageiq/providers/embedded_automation_manager.rb | class ManageIQ::Providers::EmbeddedAutomationManager < ManageIQ::Providers::AutomationManager
require_nested :Authentication
require_nested :ConfigurationScript
require_nested :ConfigurationScriptPayload
require_nested :ConfigurationScriptSource
require_nested :ConfiguredSystem
require_nested :Orchestration... | class ManageIQ::Providers::EmbeddedAutomationManager < ManageIQ::Providers::AutomationManager
require_nested :Authentication
require_nested :ConfigurationScript
require_nested :ConfigurationScriptPayload
require_nested :ConfigurationScriptSource
require_nested :ConfiguredSystem
require_nested :Orchestration... | Disable creation of embedded automation managers | Disable creation of embedded automation managers
| Ruby | apache-2.0 | ManageIQ/manageiq,romanblanco/manageiq,djberg96/manageiq,jameswnl/manageiq,billfitzgerald0120/manageiq,pkomanek/manageiq,syncrou/manageiq,juliancheal/manageiq,borod108/manageiq,chessbyte/manageiq,mkanoor/manageiq,romanblanco/manageiq,agrare/manageiq,tinaafitz/manageiq,andyvesel/manageiq,jrafanie/manageiq,skateman/manag... | ruby | ## Code Before:
class ManageIQ::Providers::EmbeddedAutomationManager < ManageIQ::Providers::AutomationManager
require_nested :Authentication
require_nested :ConfigurationScript
require_nested :ConfigurationScriptPayload
require_nested :ConfigurationScriptSource
require_nested :ConfiguredSystem
require_neste... | class ManageIQ::Providers::EmbeddedAutomationManager < ManageIQ::Providers::AutomationManager
require_nested :Authentication
require_nested :ConfigurationScript
require_nested :ConfigurationScriptPayload
require_nested :ConfigurationScriptSource
require_nested :ConfiguredSystem
require_nested ... | 4 | 0.333333 | 4 | 0 |
47b02511e8630039f4dd5485e03593ace196edc3 | manager/templates/set/edit.html | manager/templates/set/edit.html | {% extends "base.html" %}
{% load i18n %}
<!--
Title
-->
{% block title %}{% trans "Set details" %}{% endblock %}
<!--
Main Content
-->
{% block content %}
<h2>{% trans "Edit" %} {{ day.description }}</h2>
<form action="/workout/{{ workout.id}}/day/{{ day.id }}/edit/set/{% if set.id %}{{ set.id }}... | {% extends "base.html" %}
{% load i18n %}
<!--
Title
-->
{% block title %}{% trans "Set details" %}{% endblock %}
<!--
Main Content
-->
{% block content %}
<h2>{% trans "Edit" %} {{ day.description }}</h2>
<form action="/workout/{{ workout.id}}/day/{{ day.id }}/edit/set/{% if set.id %}{{ set.id }}... | Fix position of hidden CSRF fields | Fix position of hidden CSRF fields
| HTML | agpl-3.0 | DeveloperMal/wger,petervanderdoes/wger,rolandgeider/wger,petervanderdoes/wger,wger-project/wger,petervanderdoes/wger,DeveloperMal/wger,kjagoo/wger_stark,wger-project/wger,DeveloperMal/wger,wger-project/wger,rolandgeider/wger,petervanderdoes/wger,kjagoo/wger_stark,rolandgeider/wger,wger-project/wger,DeveloperMal/wger,ro... | html | ## Code Before:
{% extends "base.html" %}
{% load i18n %}
<!--
Title
-->
{% block title %}{% trans "Set details" %}{% endblock %}
<!--
Main Content
-->
{% block content %}
<h2>{% trans "Edit" %} {{ day.description }}</h2>
<form action="/workout/{{ workout.id}}/day/{{ day.id }}/edit/set/{% if set.i... | {% extends "base.html" %}
{% load i18n %}
<!--
Title
-->
{% block title %}{% trans "Set details" %}{% endblock %}
<!--
Main Content
-->
{% block content %}
<h2>{% trans "Edit" %} {{ day.description }}</h2>
<form action="/workout/{{ workout.id}}/day/{{ day.id }}/ed... | 2 | 0.04878 | 1 | 1 |
661930cc2795ffd551cf485003a987981b3f5342 | example/index.html | example/index.html | <!doctype html>
<html>
<title>zlide example</title>
<style>
* {
margin: 0;
padding: 0;
}
</style>
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.3/normalize.min.css">
<link rel="stylesheet" type="text/css" hr... | <!doctype html>
<html>
<title>zlide example</title>
<style>
* {
margin: 0;
padding: 0;
}
</style>
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.3/normalize.min.css">
<link rel="stylesheet" type="text/css" hr... | Remove css link on example | Remove css link on example
| HTML | mit | zalando/react-zlide,zalando/react-zlide | html | ## Code Before:
<!doctype html>
<html>
<title>zlide example</title>
<style>
* {
margin: 0;
padding: 0;
}
</style>
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.3/normalize.min.css">
<link rel="stylesheet" ty... | <!doctype html>
<html>
<title>zlide example</title>
<style>
* {
margin: 0;
padding: 0;
}
</style>
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/3.0.3/normalize.min.css">
- <link rel="styles... | 1 | 0.05 | 0 | 1 |
24b18d4a57776c6604203c64134f53b534ad84e0 | README.markdown | README.markdown | Find Dispatch's documentation at http://dispatch-classic.databinder.net/
| This is the classic version of Dispatch and is unmaintained.
Find Dispatch Classic's documentation at http://dispatch-classic.databinder.net/
If you're looking for the modern Dispatch, check out https://github.com/dispatch/reboot
| Update readme to link to reboot | Update readme to link to reboot | Markdown | lgpl-2.1 | dispatch/dispatch | markdown | ## Code Before:
Find Dispatch's documentation at http://dispatch-classic.databinder.net/
## Instruction:
Update readme to link to reboot
## Code After:
This is the classic version of Dispatch and is unmaintained.
Find Dispatch Classic's documentation at http://dispatch-classic.databinder.net/
If you're looking for t... | + This is the classic version of Dispatch and is unmaintained.
+
- Find Dispatch's documentation at http://dispatch-classic.databinder.net/
+ Find Dispatch Classic's documentation at http://dispatch-classic.databinder.net/
? ++++++++
+
+ If you're looking for the modern Dispatch, check out https://githu... | 6 | 6 | 5 | 1 |
012ed05c46d3e6e2901675e78b239846da0c9e9c | docs/ota-client-guide/modules/ROOT/examples/sota-local.toml | docs/ota-client-guide/modules/ROOT/examples/sota-local.toml | [provision]
provision_path = "credentials.zip"
primary_ecu_hardware_id = "local-fake"
[logger]
loglevel = 1
[storage]
path = "storage"
[pacman]
type = "none"
[uptane]
secondary_config_file = "virtualsec.json"
| [provision]
provision_path = "credentials.zip"
primary_ecu_hardware_id = "local-fake"
# This setting is for testing purposes only. Do not use in a real device.
mode = "SharedCredReuse"
[logger]
loglevel = 1
[storage]
path = "storage"
[pacman]
type = "none"
images_path = "storage/images"
[uptane]
secondary_config_fi... | Add missing configuration values to simulate a device. | Add missing configuration values to simulate a device.
Signed-off-by: Ignacio Lucero <cd2cdbf44ca497efa888e0ecb1bd58120467acb5@here.com>
| TOML | mpl-2.0 | advancedtelematic/aktualizr,advancedtelematic/aktualizr,advancedtelematic/aktualizr,advancedtelematic/aktualizr | toml | ## Code Before:
[provision]
provision_path = "credentials.zip"
primary_ecu_hardware_id = "local-fake"
[logger]
loglevel = 1
[storage]
path = "storage"
[pacman]
type = "none"
[uptane]
secondary_config_file = "virtualsec.json"
## Instruction:
Add missing configuration values to simulate a device.
Signed-off-by: Ign... | [provision]
provision_path = "credentials.zip"
primary_ecu_hardware_id = "local-fake"
+ # This setting is for testing purposes only. Do not use in a real device.
+ mode = "SharedCredReuse"
[logger]
loglevel = 1
[storage]
path = "storage"
[pacman]
type = "none"
+ images_path = "storage/images"... | 3 | 0.2 | 3 | 0 |
9a29f976c8055820702e60e593144796cae1e7b7 | app/imports/models.coffee | app/imports/models.coffee | if Meteor.isServer
Parse = require 'parse/node'
else
Parse = require 'parse'
exports.Survey = Parse.Object.extend 'Survey',
getForms: (returnMeteorCollection, collection) ->
query = @relation('forms').query()
query.find().then (forms) ->
if returnMeteorCollection and forms
formCollection = ... | if Meteor.isServer
Parse = require 'parse/node'
else
Parse = require 'parse'
exports.Survey = Parse.Object.extend 'Survey',
getForms: (returnMeteorCollection, collection) ->
query = @relation('forms').query()
query.find().then (forms) ->
if returnMeteorCollection and forms
formCollection = ... | Add getQuestions method to Form class | Add getQuestions method to Form class
| CoffeeScript | apache-2.0 | ecohealthalliance/mobile-survey,ecohealthalliance/mobile-survey,ecohealthalliance/mobile-survey | coffeescript | ## Code Before:
if Meteor.isServer
Parse = require 'parse/node'
else
Parse = require 'parse'
exports.Survey = Parse.Object.extend 'Survey',
getForms: (returnMeteorCollection, collection) ->
query = @relation('forms').query()
query.find().then (forms) ->
if returnMeteorCollection and forms
f... | if Meteor.isServer
Parse = require 'parse/node'
else
Parse = require 'parse'
exports.Survey = Parse.Object.extend 'Survey',
getForms: (returnMeteorCollection, collection) ->
query = @relation('forms').query()
query.find().then (forms) ->
if returnMeteorCollection and forms
... | 5 | 0.178571 | 5 | 0 |
1dd51b2e842e01a6752938320b7c96c1348d004f | Sources/StyledString.swift | Sources/StyledString.swift | //
// StyledString.swift
//
//
// Created by 1024jp on 2017/03/04.
//
//
struct StyledString {
let string: String
let styles: [Style]
}
struct Style {
let range: Range<String.Index>
let type: Type
}
enum StyleType {
case bold
case strike
case link(url: String)
cas... | //
// StyledString.swift
//
//
// Created by 1024jp on 2017/03/04.
//
//
struct StyledString {
let string: String
let styles: [Style]
}
struct Style {
let range: Range<String.Index>
let type: Type
enum Type {
case bold
case strike
case link... | Put styles type into Style | Put styles type into Style
| Swift | mit | 1024jp/MarkupParser | swift | ## Code Before:
//
// StyledString.swift
//
//
// Created by 1024jp on 2017/03/04.
//
//
struct StyledString {
let string: String
let styles: [Style]
}
struct Style {
let range: Range<String.Index>
let type: Type
}
enum StyleType {
case bold
case strike
case link(url:... | //
// StyledString.swift
//
//
// Created by 1024jp on 2017/03/04.
//
//
struct StyledString {
let string: String
let styles: [Style]
}
struct Style {
let range: Range<String.Index>
let type: Type
+
+
+ enum Type {
+
+ ... | 18 | 0.62069 | 9 | 9 |
5b0543bda842f022289cae88a02498fa90d6a9a1 | roles/openshift_node/tasks/storage_plugins/main.yml | roles/openshift_node/tasks/storage_plugins/main.yml | ---
# The NFS storage plugin is always enabled since it doesn't require any
# additional package dependencies
- name: NFS storage plugin configuration
include: nfs.yml
when: not openshift.common.is_containerized | bool
- name: GlusterFS storage plugin configuration
include: glusterfs.yml
when: "'glusterfs' in ... | ---
# The NFS storage plugin is always enabled since it doesn't require any
# additional package dependencies
- name: NFS storage plugin configuration
include: nfs.yml
- name: GlusterFS storage plugin configuration
include: glusterfs.yml
when: "'glusterfs' in openshift.node.storage_plugin_deps"
- name: Ceph sto... | Remove not is_containerized restriction on storage plugin includes. | Remove not is_containerized restriction on storage plugin includes.
| YAML | apache-2.0 | ewolinetz/openshift-ansible,anpingli/openshift-ansible,zhiwliu/openshift-ansible,abutcher/openshift-ansible,EricMountain-1A/openshift-ansible,jwhonce/openshift-ansible,nhr/openshift-ansible,thoraxe/openshift-ansible,EricMountain-1A/openshift-ansible,thoraxe/openshift-ansible,zhiwliu/openshift-ansible,akubicharm/openshi... | yaml | ## Code Before:
---
# The NFS storage plugin is always enabled since it doesn't require any
# additional package dependencies
- name: NFS storage plugin configuration
include: nfs.yml
when: not openshift.common.is_containerized | bool
- name: GlusterFS storage plugin configuration
include: glusterfs.yml
when: ... | ---
# The NFS storage plugin is always enabled since it doesn't require any
# additional package dependencies
- name: NFS storage plugin configuration
include: nfs.yml
- when: not openshift.common.is_containerized | bool
- name: GlusterFS storage plugin configuration
include: glusterfs.yml
- wh... | 5 | 0.357143 | 2 | 3 |
cbfe210eadfb6fc0fac9e78d184cb3ca7bade442 | README.md | README.md |
This wiki is the main source of documentation for OADA developers.
Documentation will be built over time as the project progresses. We're in the
early stages now, so please help build out some documentation, or check back
soon for changes.
| Contributing | Functional Spec | Rest API Spec | Demonstrations |
|--------... |
This wiki is the main source of documentation for OADA developers.
Documentation will be built over time as the project progresses. We're in the
early stages now, so please help build out some documentation, or check back
soon for changes.
| Contributing | Functional Spec | Rest API Spec | Demonstrations |
|--------... | Remove old link (new site apparently broke it) | Remove old link (new site apparently broke it)
| Markdown | apache-2.0 | OADA/oada-docs,OADA/oada-docs | markdown | ## Code Before:
This wiki is the main source of documentation for OADA developers.
Documentation will be built over time as the project progresses. We're in the
early stages now, so please help build out some documentation, or check back
soon for changes.
| Contributing | Functional Spec | Rest API Spec | Demonstrat... |
This wiki is the main source of documentation for OADA developers.
Documentation will be built over time as the project progresses. We're in the
early stages now, so please help build out some documentation, or check back
soon for changes.
| Contributing | Functional Spec | Rest API Spec | Demonstratio... | 1 | 0.047619 | 0 | 1 |
18d460dda5125651e98adf349cef2469a6933a77 | index.js | index.js | const Telegraf = require('telegraf');
const bot = new Telegraf(process.env.BOT_TOKEN);
function repeatIt(messageText = '') {
const timesPosition = messageText.indexOf(' ');
const times = messageText.substring(0, timesPosition);
const text = messageText.substring(timesPosition);
let answer = '';
for (let i =... | const Telegraf = require('telegraf');
const BOT_TOKEN = process.env.BOT_TOKEN || '';
const PORT = process.env.PORT || 3000;
const URL = process.env.URL || '';
const bot = new Telegraf(BOT_TOKEN);
bot.telegram.setWebhook(`${URL}/bot${BOT_TOKEN}`);
bot.startWebhook(`/bot${BOT_TOKEN}`, null, PORT);
function repeatIt(me... | Use webhooks and ready for heroku! | Use webhooks and ready for heroku!
| JavaScript | mit | newvertex/repeatitbot | javascript | ## Code Before:
const Telegraf = require('telegraf');
const bot = new Telegraf(process.env.BOT_TOKEN);
function repeatIt(messageText = '') {
const timesPosition = messageText.indexOf(' ');
const times = messageText.substring(0, timesPosition);
const text = messageText.substring(timesPosition);
let answer = ''... | const Telegraf = require('telegraf');
+
+ const BOT_TOKEN = process.env.BOT_TOKEN || '';
+ const PORT = process.env.PORT || 3000;
+ const URL = process.env.URL || '';
+
- const bot = new Telegraf(process.env.BOT_TOKEN);
? ------------
+ const bot = new Telegraf(BOT_TOKEN);
+ bot.telegram.s... | 13 | 0.541667 | 10 | 3 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.