commit
stringlengths
40
40
old_file
stringlengths
4
237
new_file
stringlengths
4
237
old_contents
stringlengths
1
4.24k
new_contents
stringlengths
5
4.84k
subject
stringlengths
15
778
message
stringlengths
16
6.86k
lang
stringlengths
1
30
license
stringclasses
13 values
repos
stringlengths
5
116k
config
stringlengths
1
30
content
stringlengths
105
8.72k
de4c67c5fadc85dc0e66aafb6d5a6e24b41586cf
app/views/layouts/_theme.html.haml
app/views/layouts/_theme.html.haml
- if theme - if theme[:pack] != 'common' && theme[:common] = render partial: 'layouts/theme', object: theme[:common] - if theme[:pack] - pack_path = theme[:flavour] ? "flavours/#{theme[:flavour]}/#{theme[:pack]}" : "core/#{theme[:pack]}" = javascript_pack_tag pack_path, crossorigin: 'anonymous' - if theme[:skin] - if !theme[:flavour] || theme[:skin] == 'default' = stylesheet_pack_tag pack_path, media: 'all', crossorigin: 'anonymous' - else = stylesheet_pack_tag "skins/#{theme[:flavour]}/#{theme[:skin]}/#{theme[:pack]}", crossorigin: 'anonymous' - if theme[:preload] - theme[:preload].each do |link| %link{ href: asset_pack_path("#{link}.js"), crossorigin: 'anonymous', rel: 'preload', as: 'script' }/
- if theme - if theme[:pack] != 'common' && theme[:common] = render partial: 'layouts/theme', object: theme[:common] - if theme[:pack] - pack_path = theme[:flavour] ? "flavours/#{theme[:flavour]}/#{theme[:pack]}" : "core/#{theme[:pack]}" = javascript_pack_tag pack_path, crossorigin: 'anonymous' - if theme[:skin] - if !theme[:flavour] || theme[:skin] == 'default' = stylesheet_pack_tag pack_path, media: 'all', crossorigin: 'anonymous' - else = stylesheet_pack_tag "skins/#{theme[:flavour]}/#{theme[:skin]}/#{theme[:pack]}", media: 'all', crossorigin: 'anonymous' - if theme[:preload] - theme[:preload].each do |link| %link{ href: asset_pack_path("#{link}.js"), crossorigin: 'anonymous', rel: 'preload', as: 'script' }/
Fix missing media: 'all' on default skins
Fix missing media: 'all' on default skins
Haml
agpl-3.0
glitch-soc/mastodon,Kirishima21/mastodon,im-in-space/mastodon,glitch-soc/mastodon,glitch-soc/mastodon,Kirishima21/mastodon,Kirishima21/mastodon,im-in-space/mastodon,im-in-space/mastodon,im-in-space/mastodon,glitch-soc/mastodon,Kirishima21/mastodon
haml
## Code Before: - if theme - if theme[:pack] != 'common' && theme[:common] = render partial: 'layouts/theme', object: theme[:common] - if theme[:pack] - pack_path = theme[:flavour] ? "flavours/#{theme[:flavour]}/#{theme[:pack]}" : "core/#{theme[:pack]}" = javascript_pack_tag pack_path, crossorigin: 'anonymous' - if theme[:skin] - if !theme[:flavour] || theme[:skin] == 'default' = stylesheet_pack_tag pack_path, media: 'all', crossorigin: 'anonymous' - else = stylesheet_pack_tag "skins/#{theme[:flavour]}/#{theme[:skin]}/#{theme[:pack]}", crossorigin: 'anonymous' - if theme[:preload] - theme[:preload].each do |link| %link{ href: asset_pack_path("#{link}.js"), crossorigin: 'anonymous', rel: 'preload', as: 'script' }/ ## Instruction: Fix missing media: 'all' on default skins ## Code After: - if theme - if theme[:pack] != 'common' && theme[:common] = render partial: 'layouts/theme', object: theme[:common] - if theme[:pack] - pack_path = theme[:flavour] ? "flavours/#{theme[:flavour]}/#{theme[:pack]}" : "core/#{theme[:pack]}" = javascript_pack_tag pack_path, crossorigin: 'anonymous' - if theme[:skin] - if !theme[:flavour] || theme[:skin] == 'default' = stylesheet_pack_tag pack_path, media: 'all', crossorigin: 'anonymous' - else = stylesheet_pack_tag "skins/#{theme[:flavour]}/#{theme[:skin]}/#{theme[:pack]}", media: 'all', crossorigin: 'anonymous' - if theme[:preload] - theme[:preload].each do |link| %link{ href: asset_pack_path("#{link}.js"), crossorigin: 'anonymous', rel: 'preload', as: 'script' }/
2a51f8b7dd0e43ec640653354fe45a10697b3c08
lib/tasks/publishing_api.rake
lib/tasks/publishing_api.rake
require 'logger' require 'gds_api/publishing_api' require 'gds_api/publishing_api/special_route_publisher' namespace :publishing_api do desc 'Publish special routes via publishing api' task publish_special_routes: :environment do special_route_publisher = GdsApi::PublishingApi::SpecialRoutePublisher.new(logger: Logger.new(STDOUT)) special_route_publisher.publish( title: 'HMRC contacts finder', description: 'A filterable list of contact information from HMRC', content_id: 'b110c03c-3f8d-4327-906b-17ebd872e6a6', base_path: '/government/organisations/hm-revenue-customs/contact', type: 'exact', publishing_app: 'contacts-admin', rendering_app: 'contacts-frontend-old', ) end end
require 'logger' require 'gds_api/publishing_api' require 'gds_api/publishing_api/special_route_publisher' namespace :publishing_api do desc 'Publish special routes via publishing api' task publish_special_routes: :environment do special_route_publisher = GdsApi::PublishingApi::SpecialRoutePublisher.new(logger: Logger.new(STDOUT)) special_route_publisher.publish( title: 'HMRC contacts finder', description: 'A filterable list of contact information from HMRC', content_id: 'b110c03c-3f8d-4327-906b-17ebd872e6a6', base_path: '/government/organisations/hm-revenue-customs/contact', type: 'exact', publishing_app: 'contacts-admin', rendering_app: 'contacts-frontend-old', ) end end desc "Temporary alias of publishing_api:publish_special_routes for backward compatibility" task "router:register" => "publishing_api:publish_special_routes"
Add temporary alias for router:register
Add temporary alias for router:register this will make it easier to merge/deploy these changes as we won't need to coordinate these with changes to alphagov-deployment
Ruby
mit
alphagov/contacts-admin,alphagov/contacts-admin,alphagov/contacts-admin
ruby
## Code Before: require 'logger' require 'gds_api/publishing_api' require 'gds_api/publishing_api/special_route_publisher' namespace :publishing_api do desc 'Publish special routes via publishing api' task publish_special_routes: :environment do special_route_publisher = GdsApi::PublishingApi::SpecialRoutePublisher.new(logger: Logger.new(STDOUT)) special_route_publisher.publish( title: 'HMRC contacts finder', description: 'A filterable list of contact information from HMRC', content_id: 'b110c03c-3f8d-4327-906b-17ebd872e6a6', base_path: '/government/organisations/hm-revenue-customs/contact', type: 'exact', publishing_app: 'contacts-admin', rendering_app: 'contacts-frontend-old', ) end end ## Instruction: Add temporary alias for router:register this will make it easier to merge/deploy these changes as we won't need to coordinate these with changes to alphagov-deployment ## Code After: require 'logger' require 'gds_api/publishing_api' require 'gds_api/publishing_api/special_route_publisher' namespace :publishing_api do desc 'Publish special routes via publishing api' task publish_special_routes: :environment do special_route_publisher = GdsApi::PublishingApi::SpecialRoutePublisher.new(logger: Logger.new(STDOUT)) special_route_publisher.publish( title: 'HMRC contacts finder', description: 'A filterable list of contact information from HMRC', content_id: 'b110c03c-3f8d-4327-906b-17ebd872e6a6', base_path: '/government/organisations/hm-revenue-customs/contact', type: 'exact', publishing_app: 'contacts-admin', rendering_app: 'contacts-frontend-old', ) end end desc "Temporary alias of publishing_api:publish_special_routes for backward compatibility" task "router:register" => "publishing_api:publish_special_routes"
ec7f234b7c16096001902e067ed43f222e05b500
app/assets/stylesheets/_flashes.scss
app/assets/stylesheets/_flashes.scss
.error, #flash_failure { @include flash($error-color); } .notice, #flash_notice { @include flash($notice-color); } .success, #flash_success { @include flash($success-color); }
%flash-error, #flash_failure { @include flash($error-color); } %flash-notice, #flash_notice { @include flash($notice-color); } %flash-success, #flash_success { @include flash($success-color); }
Make flash classes into placeholder selectors
Make flash classes into placeholder selectors
SCSS
mit
cllns/bitters,craftsmen/bitters,craftsmen/bitters,oponder/bitters,innovand/bitters,armandocanals/bitters,smithdamen/bitters,maxx1128/Maxwell-bitters,thoughtbot/bitters,cllns/bitters,smithdamen/bitters,armandocanals/bitters,oponder/bitters,cllns/bitters,bodefuwa/bitters,innovand/bitters,innovand/bitters,maxx1128/Maxwell-bitters,bodefuwa/bitters,craftsmen/bitters,maxx1128/Maxwell-bitters,greyhwndz/bitters,dYale/bitters,thoughtbot/bitters,smithdamen/bitters,dYale/bitters,oponder/bitters,dYale/bitters,greyhwndz/bitters,bodefuwa/bitters,armandocanals/bitters,greyhwndz/bitters
scss
## Code Before: .error, #flash_failure { @include flash($error-color); } .notice, #flash_notice { @include flash($notice-color); } .success, #flash_success { @include flash($success-color); } ## Instruction: Make flash classes into placeholder selectors ## Code After: %flash-error, #flash_failure { @include flash($error-color); } %flash-notice, #flash_notice { @include flash($notice-color); } %flash-success, #flash_success { @include flash($success-color); }
6953b5da409a349bcf5c6674d69a5d177954ad4d
docs/.vuepress/linkcheck-skip-file.txt
docs/.vuepress/linkcheck-skip-file.txt
github.com/intellitect/coalesce/edit # fails on github actions for some reason: https://www.npmjs.com/package/
github.com/intellitect/coalesce/edit # fails on github actions randomly: https://www.npmjs.com/package/ https://knockoutjs.com/ https://github.com/IntelliTect/Coalesce
Add more skips to linkcheck to help resolve flaky build
docs: Add more skips to linkcheck to help resolve flaky build
Text
apache-2.0
IntelliTect/Coalesce,IntelliTect/Coalesce,IntelliTect/Coalesce,IntelliTect/Coalesce
text
## Code Before: github.com/intellitect/coalesce/edit # fails on github actions for some reason: https://www.npmjs.com/package/ ## Instruction: docs: Add more skips to linkcheck to help resolve flaky build ## Code After: github.com/intellitect/coalesce/edit # fails on github actions randomly: https://www.npmjs.com/package/ https://knockoutjs.com/ https://github.com/IntelliTect/Coalesce
a5fbd9882db40e7c3756a26f165fc0094b4e541f
recipes/conda-build-all/meta.yaml
recipes/conda-build-all/meta.yaml
{% set version = "1.0.1" %} package: name: conda-build-all version: {{ version }} source: fn: conda-build-all_v{{ version }}.tar.gz url: https://github.com/SciTools/conda-build-all/archive/v{{version}}.tar.gz sha256: 1e34102f9055ce99500ce8ec87933d46a482cd20b865a180f2b064b4baf345f0 build: number: 0 script: python setup.py install --single-version-externally-managed --record=record.txt entry_points: - conda-build-all = conda_build_all.cli:main requirements: build: - python - setuptools run: - python - gitpython - conda >4 - conda-build >=1.21.7 - anaconda-client - mock test: imports: - conda_build_all commands: - conda build-all --version about: license: BSD 3-clause home: https://github.com/scitools/conda-build-all summary: conda build-all is a conda subcommand which allows multiple distributions to be built (and uploaded) in a single command
{% set version = "1.0.4" %} package: name: conda-build-all version: {{ version }} source: fn: conda-build-all_v{{ version }}.tar.gz url: https://github.com/conda-tools/conda-build-all/archive/v{{version}}.tar.gz sha256: 1a2e6b89858e8a5c6c55dd0fe64e18f7730a203740507f7746149771e22d8784 build: number: 0 script: python setup.py install --single-version-externally-managed --record=record.txt noarch: python entry_points: - conda-build-all = conda_build_all.cli:main requirements: build: - python - setuptools run: - python - gitpython - conda >4 - conda-build >=1.21.7 - anaconda-client - mock test: imports: - conda_build_all commands: - conda build-all --version about: license: BSD 3-clause license_file: LICENSE home: https://github.com/conda-tools/conda-build-all summary: conda build-all is a conda subcommand which allows multiple distributions to be built (and uploaded) in a single command
Update conda-build-all recipe to version 1.0.4
Update conda-build-all recipe to version 1.0.4 Change to noarch: python package
YAML
bsd-3-clause
jjhelmus/berryconda,jjhelmus/berryconda,jjhelmus/berryconda,jjhelmus/berryconda,jjhelmus/berryconda
yaml
## Code Before: {% set version = "1.0.1" %} package: name: conda-build-all version: {{ version }} source: fn: conda-build-all_v{{ version }}.tar.gz url: https://github.com/SciTools/conda-build-all/archive/v{{version}}.tar.gz sha256: 1e34102f9055ce99500ce8ec87933d46a482cd20b865a180f2b064b4baf345f0 build: number: 0 script: python setup.py install --single-version-externally-managed --record=record.txt entry_points: - conda-build-all = conda_build_all.cli:main requirements: build: - python - setuptools run: - python - gitpython - conda >4 - conda-build >=1.21.7 - anaconda-client - mock test: imports: - conda_build_all commands: - conda build-all --version about: license: BSD 3-clause home: https://github.com/scitools/conda-build-all summary: conda build-all is a conda subcommand which allows multiple distributions to be built (and uploaded) in a single command ## Instruction: Update conda-build-all recipe to version 1.0.4 Change to noarch: python package ## Code After: {% set version = "1.0.4" %} package: name: conda-build-all version: {{ version }} source: fn: conda-build-all_v{{ version }}.tar.gz url: https://github.com/conda-tools/conda-build-all/archive/v{{version}}.tar.gz sha256: 1a2e6b89858e8a5c6c55dd0fe64e18f7730a203740507f7746149771e22d8784 build: number: 0 script: python setup.py install --single-version-externally-managed --record=record.txt noarch: python entry_points: - conda-build-all = conda_build_all.cli:main requirements: build: - python - setuptools run: - python - gitpython - conda >4 - conda-build >=1.21.7 - anaconda-client - mock test: imports: - conda_build_all commands: - conda build-all --version about: license: BSD 3-clause license_file: LICENSE home: https://github.com/conda-tools/conda-build-all summary: conda build-all is a conda subcommand which allows multiple distributions to be built (and uploaded) in a single command
64fc02aff59de85dec98c04ed20ee2356959c8ee
examples/assets/js/config.js
examples/assets/js/config.js
require.config({ baseUrl: '../', paths: { 'text': 'bower_components/requirejs-text/text', '$': 'bower_components/jquery/dist/jquery', 'bouncefix': 'bower_components/bouncefix.js/dist/bouncefix.min', 'velocity': 'bower_components/mobify-velocity/velocity', 'modal-center': 'dist/effect/modal-center', 'sheet-bottom': 'dist/effect/sheet-bottom', 'sheet-left': 'dist/effect/sheet-left', 'sheet-right': 'dist/effect/sheet-right', 'sheet-top': 'dist/effect/sheet-top', 'plugin': 'bower_components/plugin/dist/plugin.min', 'shade': 'bower_components/shade/dist/shade.min', 'pinny': 'dist/pinny' }, 'shim': { '$': { exports: '$' } } });
require.config({ baseUrl: '../', paths: { 'text': 'bower_components/requirejs-text/text', '$': 'lib/zeptojs/dist/zepto', 'bouncefix': 'bower_components/bouncefix.js/dist/bouncefix.min', 'velocity': 'bower_components/mobify-velocity/velocity', 'modal-center': 'dist/effect/modal-center', 'sheet-bottom': 'dist/effect/sheet-bottom', 'sheet-left': 'dist/effect/sheet-left', 'sheet-right': 'dist/effect/sheet-right', 'sheet-top': 'dist/effect/sheet-top', 'plugin': 'bower_components/plugin/dist/plugin.min', 'shade': 'bower_components/shade/dist/shade.min', 'pinny': 'dist/pinny' }, 'shim': { '$': { exports: '$' } } });
Switch to Zepto for examples
Switch to Zepto for examples
JavaScript
mit
mobify/pinny,mobify/pinny
javascript
## Code Before: require.config({ baseUrl: '../', paths: { 'text': 'bower_components/requirejs-text/text', '$': 'bower_components/jquery/dist/jquery', 'bouncefix': 'bower_components/bouncefix.js/dist/bouncefix.min', 'velocity': 'bower_components/mobify-velocity/velocity', 'modal-center': 'dist/effect/modal-center', 'sheet-bottom': 'dist/effect/sheet-bottom', 'sheet-left': 'dist/effect/sheet-left', 'sheet-right': 'dist/effect/sheet-right', 'sheet-top': 'dist/effect/sheet-top', 'plugin': 'bower_components/plugin/dist/plugin.min', 'shade': 'bower_components/shade/dist/shade.min', 'pinny': 'dist/pinny' }, 'shim': { '$': { exports: '$' } } }); ## Instruction: Switch to Zepto for examples ## Code After: require.config({ baseUrl: '../', paths: { 'text': 'bower_components/requirejs-text/text', '$': 'lib/zeptojs/dist/zepto', 'bouncefix': 'bower_components/bouncefix.js/dist/bouncefix.min', 'velocity': 'bower_components/mobify-velocity/velocity', 'modal-center': 'dist/effect/modal-center', 'sheet-bottom': 'dist/effect/sheet-bottom', 'sheet-left': 'dist/effect/sheet-left', 'sheet-right': 'dist/effect/sheet-right', 'sheet-top': 'dist/effect/sheet-top', 'plugin': 'bower_components/plugin/dist/plugin.min', 'shade': 'bower_components/shade/dist/shade.min', 'pinny': 'dist/pinny' }, 'shim': { '$': { exports: '$' } } });
9698eab88c20dd01d4beafa9786eddbed78e4577
app/client/views/activities/form/form.html
app/client/views/activities/form/form.html
<template name="activityForm"> {{# autoForm id="activityForm" type=formType collection="Activities" doc=activity }} <div class="modal-body"> <label for="activityTypeId"> {{_ 'activities.residentIds.label'}} </label> {{> afFieldInput name="residentIds" multiple=true options=residentsSelectOptions value=residentIds }} <label for="activityTypeId"> {{_ 'activities.activityTypeId.label'}} </label> {{> afFieldInput name="activityTypeId" options=activityTypeIdOptions }} <label for="activityDate"> {{_ 'activities.activityDate.label'}} </label> {{> afFieldInput name="activityDate" buttonClasses="fa fa-calendar" }} <label for="duration"> {{_ 'activities.duration.label'}} </label> {{> afFieldInput name="duration"}} <label for="facilitatorRoleId"> {{_ 'activities.facilitatorRoleId.label'}} </label> {{> afFieldInput name="facilitatorRoleId" options=facilitatorRoleIdOptions }} </div> <button type="submit" class="btn btn-success"> {{_ "activityForm-save" }} </button> <button type="button" class="btn btn-danger" data-dismiss="modal"> {{_ "activityForm-cancel" }} </button> {{/ autoForm }} </template>
<template name="activityForm"> {{# autoForm id="activityForm" type=formType collection="Activities" doc=activity }} <div class="modal-body"> <label for="activityTypeId"> {{_ 'activities.residentIds.label'}} </label> {{> afFieldInput name="residentIds" multiple=true options=residentsSelectOptions value=residentIds }} <label for="activityTypeId"> {{_ 'activities.activityTypeId.label'}} </label> {{> afFieldInput name="activityTypeId" options=activityTypeIdOptions }} <label for="activityDate"> {{_ 'activities.activityDate.label'}} </label> {{> afFieldInput name="activityDate" buttonClasses="fa fa-calendar" id="activityDate" }} <label for="duration"> {{_ 'activities.duration.label'}} </label> {{> afFieldInput name="duration"}} <label for="facilitatorRoleId"> {{_ 'activities.facilitatorRoleId.label'}} </label> {{> afFieldInput name="facilitatorRoleId" options=facilitatorRoleIdOptions }} </div> <button type="submit" class="btn btn-success"> {{_ "activityForm-save" }} </button> <button type="button" class="btn btn-danger" data-dismiss="modal"> {{_ "activityForm-cancel" }} </button> {{/ autoForm }} </template>
Add id to activityDate field
Add id to activityDate field
HTML
agpl-3.0
GeriLife/wellbeing,GeriLife/wellbeing,brylie/juhani-wellbeing,GeriLife/wellbeing,brylie/juhani-wellbeing,brylie/juhani-wellbeing,brylie/juhani-wellbeing,GeriLife/wellbeing
html
## Code Before: <template name="activityForm"> {{# autoForm id="activityForm" type=formType collection="Activities" doc=activity }} <div class="modal-body"> <label for="activityTypeId"> {{_ 'activities.residentIds.label'}} </label> {{> afFieldInput name="residentIds" multiple=true options=residentsSelectOptions value=residentIds }} <label for="activityTypeId"> {{_ 'activities.activityTypeId.label'}} </label> {{> afFieldInput name="activityTypeId" options=activityTypeIdOptions }} <label for="activityDate"> {{_ 'activities.activityDate.label'}} </label> {{> afFieldInput name="activityDate" buttonClasses="fa fa-calendar" }} <label for="duration"> {{_ 'activities.duration.label'}} </label> {{> afFieldInput name="duration"}} <label for="facilitatorRoleId"> {{_ 'activities.facilitatorRoleId.label'}} </label> {{> afFieldInput name="facilitatorRoleId" options=facilitatorRoleIdOptions }} </div> <button type="submit" class="btn btn-success"> {{_ "activityForm-save" }} </button> <button type="button" class="btn btn-danger" data-dismiss="modal"> {{_ "activityForm-cancel" }} </button> {{/ autoForm }} </template> ## Instruction: Add id to activityDate field ## Code After: <template name="activityForm"> {{# autoForm id="activityForm" type=formType collection="Activities" doc=activity }} <div class="modal-body"> <label for="activityTypeId"> {{_ 'activities.residentIds.label'}} </label> {{> afFieldInput name="residentIds" multiple=true options=residentsSelectOptions value=residentIds }} <label for="activityTypeId"> {{_ 'activities.activityTypeId.label'}} </label> {{> afFieldInput name="activityTypeId" options=activityTypeIdOptions }} <label for="activityDate"> {{_ 'activities.activityDate.label'}} </label> {{> afFieldInput name="activityDate" buttonClasses="fa fa-calendar" id="activityDate" }} <label for="duration"> {{_ 'activities.duration.label'}} </label> {{> afFieldInput name="duration"}} <label for="facilitatorRoleId"> {{_ 'activities.facilitatorRoleId.label'}} </label> {{> afFieldInput name="facilitatorRoleId" options=facilitatorRoleIdOptions }} </div> <button type="submit" class="btn btn-success"> {{_ "activityForm-save" }} </button> <button type="button" class="btn btn-danger" data-dismiss="modal"> {{_ "activityForm-cancel" }} </button> {{/ autoForm }} </template>
bcaa28358534bee8f5e0bfe40f33e05ac09fcd6f
lib/id_token.js
lib/id_token.js
module.exports = (provider, body, session) => { if (!/^[a-zA-Z0-9\-_]+?\.[a-zA-Z0-9\-_]+?\.([a-zA-Z0-9\-_]+)?$/.test(body.id_token)) { return {error: 'Grant: OpenID Connect invalid id_token format'} } var [header, payload, signature] = body.id_token.split('.') try { header = JSON.parse(Buffer.from(header, 'base64').toString('binary')) payload = JSON.parse(Buffer.from(payload, 'base64').toString('utf8')) } catch (err) { return {error: 'Grant: OpenID Connect error decoding id_token'} } if (payload.aud !== provider.key) { return {error: 'Grant: OpenID Connect invalid id_token audience'} } else if ((payload.nonce && session.nonce) && (payload.nonce !== session.nonce)) { return {error: 'Grant: OpenID Connect nonce mismatch'} } return {header, payload, signature} }
const isAudienceValid = (aud, key) => (Array.isArray(aud) && aud.indexOf(key) !== -1) || aud === key; module.exports = (provider, body, session) => { if (!/^[a-zA-Z0-9\-_]+?\.[a-zA-Z0-9\-_]+?\.([a-zA-Z0-9\-_]+)?$/.test(body.id_token)) { return {error: 'Grant: OpenID Connect invalid id_token format'} } var [header, payload, signature] = body.id_token.split('.') try { header = JSON.parse(Buffer.from(header, 'base64').toString('binary')) payload = JSON.parse(Buffer.from(payload, 'base64').toString('utf8')) } catch (err) { return {error: 'Grant: OpenID Connect error decoding id_token'} } if (!isAudienceValid(payload.aud, provider.key)) { return {error: 'Grant: OpenID Connect invalid id_token audience'} } else if ((payload.nonce && session.nonce) && (payload.nonce !== session.nonce)) { return {error: 'Grant: OpenID Connect nonce mismatch'} } return {header, payload, signature} }
Handle audience as an array
Handle audience as an array According to RFC7519, `aud` claim is an array of strings; only in case there's one audience, `aud` can be a string. See https://tools.ietf.org/html/rfc7519#page-9 This fix allows for audience claim to be both string and array of strings.
JavaScript
mit
simov/grant
javascript
## Code Before: module.exports = (provider, body, session) => { if (!/^[a-zA-Z0-9\-_]+?\.[a-zA-Z0-9\-_]+?\.([a-zA-Z0-9\-_]+)?$/.test(body.id_token)) { return {error: 'Grant: OpenID Connect invalid id_token format'} } var [header, payload, signature] = body.id_token.split('.') try { header = JSON.parse(Buffer.from(header, 'base64').toString('binary')) payload = JSON.parse(Buffer.from(payload, 'base64').toString('utf8')) } catch (err) { return {error: 'Grant: OpenID Connect error decoding id_token'} } if (payload.aud !== provider.key) { return {error: 'Grant: OpenID Connect invalid id_token audience'} } else if ((payload.nonce && session.nonce) && (payload.nonce !== session.nonce)) { return {error: 'Grant: OpenID Connect nonce mismatch'} } return {header, payload, signature} } ## Instruction: Handle audience as an array According to RFC7519, `aud` claim is an array of strings; only in case there's one audience, `aud` can be a string. See https://tools.ietf.org/html/rfc7519#page-9 This fix allows for audience claim to be both string and array of strings. ## Code After: const isAudienceValid = (aud, key) => (Array.isArray(aud) && aud.indexOf(key) !== -1) || aud === key; module.exports = (provider, body, session) => { if (!/^[a-zA-Z0-9\-_]+?\.[a-zA-Z0-9\-_]+?\.([a-zA-Z0-9\-_]+)?$/.test(body.id_token)) { return {error: 'Grant: OpenID Connect invalid id_token format'} } var [header, payload, signature] = body.id_token.split('.') try { header = JSON.parse(Buffer.from(header, 'base64').toString('binary')) payload = JSON.parse(Buffer.from(payload, 'base64').toString('utf8')) } catch (err) { return {error: 'Grant: OpenID Connect error decoding id_token'} } if (!isAudienceValid(payload.aud, provider.key)) { return {error: 'Grant: OpenID Connect invalid id_token audience'} } else if ((payload.nonce && session.nonce) && (payload.nonce !== session.nonce)) { return {error: 'Grant: OpenID Connect nonce mismatch'} } return {header, payload, signature} }
0ddb6d17ee3af80ff9ebacd9e194f2bdce5d6360
upstart/noweats.sh
upstart/noweats.sh
pid_collect= cleanup() { kill $! exit 0 } trap "cleanup" SIGINT SIGTERM EXIT /bin/mkdir -p /home/reissb/noweats_data/collect . /home/reissb/.virtualenvs/noweats/bin/activate # Collect tweets in the background. collect_nyc /home/reissb/noweats_data/collect 2>&1 | /usr/bin/logger -t noweats & # Process tweets every 5 minutes. This helps when we fall behind. while true; do /usr/bin/nice -n 19 process_new \ /home/reissb/noweats_data/collect /home/reissb/noweats_data/output /usr/bin/rsync -cr /home/reissb/noweats_data/output/ \ [email protected]:~/public_html/noweats/data/ sleep 300.0 done
cleanup() { kill $! exit 0 } try_start_collect() { if ! pgrep 'collect_nyc' >/dev/null 2>&1; then # Collect tweets in the background. collect_nyc /home/reissb/noweats_data/collect 2>&1 | /usr/bin/logger -t noweats & fi } trap "cleanup" SIGINT SIGTERM EXIT /bin/mkdir -p /home/reissb/noweats_data/collect . /home/reissb/.virtualenvs/noweats/bin/activate # Process tweets every 5 minutes. This helps when we fall behind. while true; do try_start_collect /usr/bin/nice -n 19 process_new \ /home/reissb/noweats_data/collect /home/reissb/noweats_data/output /usr/bin/rsync -cr /home/reissb/noweats_data/output/ \ [email protected]:~/public_html/noweats/data/ sleep 300.0 done
Make upstart service more robust.
Make upstart service more robust. Connection errors could bring down the collect script (or it seemed so). If it's not running, then have upstart bring it up.
Shell
mit
blr246/noweats,blr246/noweats
shell
## Code Before: pid_collect= cleanup() { kill $! exit 0 } trap "cleanup" SIGINT SIGTERM EXIT /bin/mkdir -p /home/reissb/noweats_data/collect . /home/reissb/.virtualenvs/noweats/bin/activate # Collect tweets in the background. collect_nyc /home/reissb/noweats_data/collect 2>&1 | /usr/bin/logger -t noweats & # Process tweets every 5 minutes. This helps when we fall behind. while true; do /usr/bin/nice -n 19 process_new \ /home/reissb/noweats_data/collect /home/reissb/noweats_data/output /usr/bin/rsync -cr /home/reissb/noweats_data/output/ \ [email protected]:~/public_html/noweats/data/ sleep 300.0 done ## Instruction: Make upstart service more robust. Connection errors could bring down the collect script (or it seemed so). If it's not running, then have upstart bring it up. ## Code After: cleanup() { kill $! exit 0 } try_start_collect() { if ! pgrep 'collect_nyc' >/dev/null 2>&1; then # Collect tweets in the background. collect_nyc /home/reissb/noweats_data/collect 2>&1 | /usr/bin/logger -t noweats & fi } trap "cleanup" SIGINT SIGTERM EXIT /bin/mkdir -p /home/reissb/noweats_data/collect . /home/reissb/.virtualenvs/noweats/bin/activate # Process tweets every 5 minutes. This helps when we fall behind. while true; do try_start_collect /usr/bin/nice -n 19 process_new \ /home/reissb/noweats_data/collect /home/reissb/noweats_data/output /usr/bin/rsync -cr /home/reissb/noweats_data/output/ \ [email protected]:~/public_html/noweats/data/ sleep 300.0 done
1a0fd2be7ec810a6dcc7e88b6ea4e10d91111acf
server/db/controllers/getUserIdsGivenSelfIdAndRelationshipType.js
server/db/controllers/getUserIdsGivenSelfIdAndRelationshipType.js
const db = require('../db.js'); const Sequelize = require('sequelize'); const getUserIdsGivenSelfIdAndRelationshipType = (selfId, relationshipType) => { const queryStr = `SELECT users.id FROM users INNER JOIN relationships ON users.id = relationships.user1Id OR users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = ${relationshipType} `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); }; exports.getConnections = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'connection'); exports.getRejects = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'reject'); exports.getRequests = (selfId) => { const queryStr = `SELECT users.id FROM users INNER JOIN relationships ON users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = 'request' `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); };
const db = require('../db.js'); const Sequelize = require('sequelize'); const getUserIdsGivenSelfIdAndRelationshipType = (selfId, relationshipType) => { const queryStr = `SELECT users.id FROM users INNER JOIN relationships ON users.id = relationships.user1Id OR users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = ${relationshipType} `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); }; exports.getConnections = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'connection'); exports.getRejects = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'reject'); exports.getRequests = (selfId) => { const queryStr = `SELECT relationships.user1Id FROM users INNER JOIN relationships ON users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = 'request' `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); };
Return sender ids instead of recipient id
Return sender ids instead of recipient id
JavaScript
mit
VictoriousResistance/iDioma,VictoriousResistance/iDioma
javascript
## Code Before: const db = require('../db.js'); const Sequelize = require('sequelize'); const getUserIdsGivenSelfIdAndRelationshipType = (selfId, relationshipType) => { const queryStr = `SELECT users.id FROM users INNER JOIN relationships ON users.id = relationships.user1Id OR users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = ${relationshipType} `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); }; exports.getConnections = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'connection'); exports.getRejects = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'reject'); exports.getRequests = (selfId) => { const queryStr = `SELECT users.id FROM users INNER JOIN relationships ON users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = 'request' `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); }; ## Instruction: Return sender ids instead of recipient id ## Code After: const db = require('../db.js'); const Sequelize = require('sequelize'); const getUserIdsGivenSelfIdAndRelationshipType = (selfId, relationshipType) => { const queryStr = `SELECT users.id FROM users INNER JOIN relationships ON users.id = relationships.user1Id OR users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = ${relationshipType} `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); }; exports.getConnections = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'connection'); exports.getRejects = (selfId) => getUserIdsGivenSelfIdAndRelationshipType(selfId, 'reject'); exports.getRequests = (selfId) => { const queryStr = `SELECT relationships.user1Id FROM users INNER JOIN relationships ON users.id = relationships.user2Id WHERE users.id = ${selfId} AND relationships.type = 'request' `; return db.query(queryStr, { type: Sequelize.QueryTypes.SELECT }); };
fc4ef63f43c7e9d4d5e444448d2a76e7932626c0
packages/ph/phonetic-languages-plus.yaml
packages/ph/phonetic-languages-plus.yaml
homepage: https://hackage.haskell.org/package/phonetic-languages-plus changelog-type: markdown hash: dc03614253da3563dd1282e619afc7bf86c01544f438abc62a8f26d1f030aacc test-bench-deps: {} maintainer: [email protected] synopsis: Some common shared between different packages functions. changelog: | # Revision history for phonetic-languages-plus ## 0.1.0.0 -- 2020-10-30 * First version. Released on an unsuspecting world. basic-deps: lists-flines: '>=0.1.1 && <1' bytestring: '>=0.10 && <0.13' base: '>=4.7 && <4.15' parallel: '>=3.2.0.6 && <4' uniqueness-periods-vector-stats: '>=0.1.2 && <1' all-versions: - 0.1.0.0 author: OleksandrZhabenko latest: 0.1.0.0 description-type: haddock description: Among them are the uniqueness-periods-vector series. license-name: MIT
homepage: https://hackage.haskell.org/package/phonetic-languages-plus changelog-type: markdown hash: 83495eedd621f9bf57f49a65451784e0048f969b9d93f6e06c40edf9effeb0f6 test-bench-deps: {} maintainer: [email protected] synopsis: Some common shared between different packages functions. changelog: | # Revision history for phonetic-languages-plus ## 0.1.0.0 -- 2020-10-30 * First version. Released on an unsuspecting world. basic-deps: lists-flines: '>=0.1.1 && <1' bytestring: '>=0.10 && <0.13' base: '>=4.7 && <4.15' parallel: '>=3.2.0.6 && <4' uniqueness-periods-vector-stats: '>=0.2 && <1' all-versions: - 0.1.1.0 author: OleksandrZhabenko latest: 0.1.1.0 description-type: haddock description: Among them are the uniqueness-periods-vector series. license-name: MIT
Update from Hackage at 2020-12-05T13:45:43Z
Update from Hackage at 2020-12-05T13:45:43Z
YAML
mit
commercialhaskell/all-cabal-metadata
yaml
## Code Before: homepage: https://hackage.haskell.org/package/phonetic-languages-plus changelog-type: markdown hash: dc03614253da3563dd1282e619afc7bf86c01544f438abc62a8f26d1f030aacc test-bench-deps: {} maintainer: [email protected] synopsis: Some common shared between different packages functions. changelog: | # Revision history for phonetic-languages-plus ## 0.1.0.0 -- 2020-10-30 * First version. Released on an unsuspecting world. basic-deps: lists-flines: '>=0.1.1 && <1' bytestring: '>=0.10 && <0.13' base: '>=4.7 && <4.15' parallel: '>=3.2.0.6 && <4' uniqueness-periods-vector-stats: '>=0.1.2 && <1' all-versions: - 0.1.0.0 author: OleksandrZhabenko latest: 0.1.0.0 description-type: haddock description: Among them are the uniqueness-periods-vector series. license-name: MIT ## Instruction: Update from Hackage at 2020-12-05T13:45:43Z ## Code After: homepage: https://hackage.haskell.org/package/phonetic-languages-plus changelog-type: markdown hash: 83495eedd621f9bf57f49a65451784e0048f969b9d93f6e06c40edf9effeb0f6 test-bench-deps: {} maintainer: [email protected] synopsis: Some common shared between different packages functions. changelog: | # Revision history for phonetic-languages-plus ## 0.1.0.0 -- 2020-10-30 * First version. Released on an unsuspecting world. basic-deps: lists-flines: '>=0.1.1 && <1' bytestring: '>=0.10 && <0.13' base: '>=4.7 && <4.15' parallel: '>=3.2.0.6 && <4' uniqueness-periods-vector-stats: '>=0.2 && <1' all-versions: - 0.1.1.0 author: OleksandrZhabenko latest: 0.1.1.0 description-type: haddock description: Among them are the uniqueness-periods-vector series. license-name: MIT
88b6d87898f366373632773773616de31be55229
README.md
README.md
[ ![Codeship Status for bsedg/irest](https://codeship.com/projects/1f8bd7f0-598d-0134-a57b-0ac50249f2fe/status?branch=master)](https://codeship.com/projects/173070) [![Go Report Card](https://goreportcard.com/badge/github.com/bsedg/tasker)](https://goreportcard.com/report/github.com/bsedg/tasker) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) Tasker is a service to manage tasks that can be scheduled.
[ ![Codeship Status for bsedg/irest](https://codeship.com/projects/1f8bd7f0-598d-0134-a57b-0ac50249f2fe/status?branch=master)](https://codeship.com/projects/173070) [![Go Report Card](https://goreportcard.com/badge/github.com/bsedg/tasker)](https://goreportcard.com/report/github.com/bsedg/tasker) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) Tasker is a service to manage tasks that can be scheduled. ## Development ``` # build the service docker-compose build # run the service docker-compose up # assuming 'dockerhost' for the host # create a task curl -i -X POST dockerhost:8080/tasks \ -d '{"name": "test", "action": "noop", "time": "now"}' # get all tasks curl -i dockerhost:8080/tasks ```
Add development section to readme.
Add development section to readme.
Markdown
mit
bsedg/tasker
markdown
## Code Before: [ ![Codeship Status for bsedg/irest](https://codeship.com/projects/1f8bd7f0-598d-0134-a57b-0ac50249f2fe/status?branch=master)](https://codeship.com/projects/173070) [![Go Report Card](https://goreportcard.com/badge/github.com/bsedg/tasker)](https://goreportcard.com/report/github.com/bsedg/tasker) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) Tasker is a service to manage tasks that can be scheduled. ## Instruction: Add development section to readme. ## Code After: [ ![Codeship Status for bsedg/irest](https://codeship.com/projects/1f8bd7f0-598d-0134-a57b-0ac50249f2fe/status?branch=master)](https://codeship.com/projects/173070) [![Go Report Card](https://goreportcard.com/badge/github.com/bsedg/tasker)](https://goreportcard.com/report/github.com/bsedg/tasker) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT) Tasker is a service to manage tasks that can be scheduled. ## Development ``` # build the service docker-compose build # run the service docker-compose up # assuming 'dockerhost' for the host # create a task curl -i -X POST dockerhost:8080/tasks \ -d '{"name": "test", "action": "noop", "time": "now"}' # get all tasks curl -i dockerhost:8080/tasks ```
b772907b2d527ea471dcaaab3a078ae81ad3ba3e
types/cors/cors-tests.ts
types/cors/cors-tests.ts
import express = require('express'); import cors = require('cors'); const app = express(); app.use(cors()); app.use(cors({ maxAge: 100, credentials: true, optionsSuccessStatus: 200 })); app.use(cors({ methods: 'GET,POST,PUT', exposedHeaders: 'Content-Range,X-Content-Range', allowedHeaders: 'Content-Type,Authorization' })); app.use(cors({ methods: ['GET', 'POST', 'PUT', 'DELETE'], exposedHeaders: ['Content-Range', 'X-Content-Range'], allowedHeaders: ['Content-Type', 'Authorization'] })); app.use(cors({ origin: true })); app.use(cors({ origin: 'http://example.com' })); app.use(cors({ origin: /example\.com$/ })); app.use(cors({ origin: ['http://example.com', 'http://fakeurl.com'] })); app.use(cors({ origin: [/example\.com$/, /fakeurl\.com$/] })); app.use(cors({ origin: (requestOrigin, cb) => { try { const allow = requestOrigin.indexOf('.edu') !== -1; cb(null, allow); } catch (err) { cb(err); } } }));
import express = require('express'); import cors = require('cors'); const app = express(); app.use(cors()); app.use(cors({ maxAge: 100, credentials: true, optionsSuccessStatus: 200 })); app.use(cors({ methods: 'GET,POST,PUT', exposedHeaders: 'Content-Range,X-Content-Range', allowedHeaders: 'Content-Type,Authorization' })); app.use(cors({ methods: ['GET', 'POST', 'PUT', 'DELETE'], exposedHeaders: ['Content-Range', 'X-Content-Range'], allowedHeaders: ['Content-Type', 'Authorization'] })); app.use(cors({ origin: true })); app.use(cors({ origin: 'http://example.com' })); app.use(cors({ origin: /example\.com$/ })); app.use(cors({ origin: [/example\.com$/, 'http://example.com'] })); app.use(cors({ origin: ['http://example.com', 'http://fakeurl.com'] })); app.use(cors({ origin: [/example\.com$/, /fakeurl\.com$/] })); app.use(cors({ origin: (requestOrigin, cb) => { try { const allow = requestOrigin.indexOf('.edu') !== -1; cb(null, allow); } catch (err) { cb(err); } } }));
Add test for mixed type array
Add test for mixed type array
TypeScript
mit
zuzusik/DefinitelyTyped,aciccarello/DefinitelyTyped,zuzusik/DefinitelyTyped,AgentME/DefinitelyTyped,georgemarshall/DefinitelyTyped,AbraaoAlves/DefinitelyTyped,arusakov/DefinitelyTyped,borisyankov/DefinitelyTyped,aciccarello/DefinitelyTyped,dsebastien/DefinitelyTyped,benliddicott/DefinitelyTyped,rolandzwaga/DefinitelyTyped,AbraaoAlves/DefinitelyTyped,zuzusik/DefinitelyTyped,chrootsu/DefinitelyTyped,aciccarello/DefinitelyTyped,georgemarshall/DefinitelyTyped,AgentME/DefinitelyTyped,dsebastien/DefinitelyTyped,chrootsu/DefinitelyTyped,alexdresko/DefinitelyTyped,rolandzwaga/DefinitelyTyped,AbraaoAlves/DefinitelyTyped,one-pieces/DefinitelyTyped,borisyankov/DefinitelyTyped,markogresak/DefinitelyTyped,AgentME/DefinitelyTyped,georgemarshall/DefinitelyTyped,arusakov/DefinitelyTyped,arusakov/DefinitelyTyped,mcliment/DefinitelyTyped,georgemarshall/DefinitelyTyped,magny/DefinitelyTyped,magny/DefinitelyTyped,alexdresko/DefinitelyTyped,AgentME/DefinitelyTyped,laurentiustamate94/DefinitelyTyped
typescript
## Code Before: import express = require('express'); import cors = require('cors'); const app = express(); app.use(cors()); app.use(cors({ maxAge: 100, credentials: true, optionsSuccessStatus: 200 })); app.use(cors({ methods: 'GET,POST,PUT', exposedHeaders: 'Content-Range,X-Content-Range', allowedHeaders: 'Content-Type,Authorization' })); app.use(cors({ methods: ['GET', 'POST', 'PUT', 'DELETE'], exposedHeaders: ['Content-Range', 'X-Content-Range'], allowedHeaders: ['Content-Type', 'Authorization'] })); app.use(cors({ origin: true })); app.use(cors({ origin: 'http://example.com' })); app.use(cors({ origin: /example\.com$/ })); app.use(cors({ origin: ['http://example.com', 'http://fakeurl.com'] })); app.use(cors({ origin: [/example\.com$/, /fakeurl\.com$/] })); app.use(cors({ origin: (requestOrigin, cb) => { try { const allow = requestOrigin.indexOf('.edu') !== -1; cb(null, allow); } catch (err) { cb(err); } } })); ## Instruction: Add test for mixed type array ## Code After: import express = require('express'); import cors = require('cors'); const app = express(); app.use(cors()); app.use(cors({ maxAge: 100, credentials: true, optionsSuccessStatus: 200 })); app.use(cors({ methods: 'GET,POST,PUT', exposedHeaders: 'Content-Range,X-Content-Range', allowedHeaders: 'Content-Type,Authorization' })); app.use(cors({ methods: ['GET', 'POST', 'PUT', 'DELETE'], exposedHeaders: ['Content-Range', 'X-Content-Range'], allowedHeaders: ['Content-Type', 'Authorization'] })); app.use(cors({ origin: true })); app.use(cors({ origin: 'http://example.com' })); app.use(cors({ origin: /example\.com$/ })); app.use(cors({ origin: [/example\.com$/, 'http://example.com'] })); app.use(cors({ origin: ['http://example.com', 'http://fakeurl.com'] })); app.use(cors({ origin: [/example\.com$/, /fakeurl\.com$/] })); app.use(cors({ origin: (requestOrigin, cb) => { try { const allow = requestOrigin.indexOf('.edu') !== -1; cb(null, allow); } catch (err) { cb(err); } } }));
4ec1f41057515d3667d160a0f5fe539b73599dfd
update_kb_bsfcampus_sen.yml
update_kb_bsfcampus_sen.yml
--- # Ansible playbook for BSF Campus Sénégale #It will be always localhost - hosts: localhost roles: - tinc-static # Start. has to be always enable - logs # Stop. has to be always enable
--- # Ansible playbook for BSF Campus Sénégale #It will be always localhost - hosts: localhost roles: - { role: upgradeIdc, when: ansible_hostname == 'kb-bsfcampus-sen-76' } - tinc-static # Start. has to be always enable - logs # Stop. has to be always enable
Enable the upgrade of Ideascube on KoomBook 76
Enable the upgrade of Ideascube on KoomBook 76
YAML
mit
ideascube/ansiblecube,ideascube/ansiblecube
yaml
## Code Before: --- # Ansible playbook for BSF Campus Sénégale #It will be always localhost - hosts: localhost roles: - tinc-static # Start. has to be always enable - logs # Stop. has to be always enable ## Instruction: Enable the upgrade of Ideascube on KoomBook 76 ## Code After: --- # Ansible playbook for BSF Campus Sénégale #It will be always localhost - hosts: localhost roles: - { role: upgradeIdc, when: ansible_hostname == 'kb-bsfcampus-sen-76' } - tinc-static # Start. has to be always enable - logs # Stop. has to be always enable
a4db7ec63c4692ff7d279955110ac11a6f794fb2
site/_layouts/docs.html
site/_layouts/docs.html
--- layout: default --- <section class="docs"> <div class="grid"> {% include docs_contents_mobile.html %} <div class="unit four-fifths"> <article> <div class="improve right"> <a href="https://github.com/jekyll/jekyll/edit/master/site/{{ page.path }}">Improve this page <i class="fa fa-pencil"></i></a> </div> <h1>{{ page.title }}</h1> {{ content }} {% include section_nav.html %} </article> </div> {% include docs_contents.html %} <div class="clear"></div> </div> </section>
--- layout: default --- <section class="docs"> <div class="grid"> {% include docs_contents_mobile.html %} <div class="unit four-fifths"> <article> <div class="improve right"> <a href="https://github.com/jekyll/jekyll/edit/master/site/{{ page.path }}"><i class="fa fa-pencil"></i> &nbsp;Improve this page</a> </div> <h1>{{ page.title }}</h1> {{ content }} {% include section_nav.html %} </article> </div> {% include docs_contents.html %} <div class="clear"></div> </div> </section>
Put the pencil icon in front of the improve link.
Put the pencil icon in front of the improve link. Signed-off-by: Martin Jorn Rogalla <[email protected]>
HTML
mit
nemotan/jekyll,penchan1218/jekyllcn,tillgrallert/jekyll,vidbina/jekyll,rongl/jekyll,Tyrion22/jekyll,desidude03/jekyll,stomar/jekyll,rajrathore/jekyll,LuoPX-15510486969/jekyll,LeuisKen/jekyllcn,princeofdarkness76/jekyll,larryfox/jekyll,Strangehill/jekyll,anthonyrosengren/grasshoppergathering2.github-io,shliujing/jekyll,alihalabyah/jekyll,julienbourdeau/jekyll,ajhit406/jekyll,rongl/jekyll,adilapapaya/jekyll,nasht00/jekyll,xtymichael/jekyll,Tiger66639/jekyll,xiongjungit/jekyll,noikiy/jekyll,royalwang/jekyll,jeffkole/jekyll,tomasdiez/jekyll,xiongjungit/jekyll,fulldecent/jekyll,eloyesp/jekyll,tamouse/jekyll,PepSalehi/jekyll,0x00evil/jekyll,ajhit406/jekyll,Teino1978-Corp/Teino1978-Corp-jekyll,Tiger66639/jekyll,sasongkojati/jekyll,angeliaz/jekyll,nateberkopec/jekyll,xiebinhqy/jklly_china,jekyll/jekyll,EddieDow/jekyll,darwin/jekyll,tareq-s/jekyll,teju111/jekyll,liukaijv/jekyll,sasongkojati/jekyll,xantage/jekyll,jmptrader/jekyll,AaronSikes/jekyll,iRoxx/jekyll,ducktyper/jekyll,brint/jekyll,ajhit406/jekyll,backendeveloper/jekyll,tomjohnson1492/jekyll,thejameskyle/jekyll,hartmel/jekyll,jaroot32/jekyll,Kinghack/kinghack.github.com,chinayin/jekyll,thetaxman/jekyll,LeuisKen/jekyllcn,alfredxing/jekyll,indraj/jekyll,trungvothanh/jekyll,kimeng/jekyll,dangaute/eng,aarvay/jekyll,jaybe-jekyll/jekyll,Wirachmat/jekyll,jaybe-jekyll/jekyll,ZainRizvi/jekyll,bsmr-ruby/jekyll,mnuessler/jekyll,princeofdarkness76/jekyll,oresmus/jekyll,PepSalehi/jekyll,tugberkugurlu/jekyll,fulldecent/jekyll,tugberkugurlu/jekyll,fengsmith/jekyllcn,rovrevik/jekyll,nickg33/jekyll,imaustink/jekyll,CPVPLachlan/CPVP-Blog,royalwang/jekyll,gkunwar/gkunwar.github.io,richsoni/jekyll,princeofdarkness76/jekyll,fabulousu/jekyll,yhironaka/yhironaka.github.io,MjAbuz/jekyll,wentixiaogege/jekyll,zsyed91/jekyll,chrisfinazzo/jekyll,naughtyboy83/jekyll,digideskio/jekyll,fulldecent/jekyll,codeclimate-testing/jekyll,chrisfinazzo/jekyll,nateberkopec/jekyll,isathish/jekyll,derekgottlieb/jekyll,christophermanning/jekyll,eninya/jekyll,brint/jekyll,PepSalehi/jekyll,tomasdiez/jekyll,kimeng/jekyll,likong/jekyll,larryfox/jekyll,rasa2011/rasa2011.github.io,stomar/jekyll,marrujoalex/jekyll,desidude03/jekyll,MjAbuz/jekyll,tylermachen/jekyll,adilapapaya/jekyll,eninya/jekyll,xcatliu/jekyllcn,mixxmac/jekyll,backendeveloper/jekyll,brint/jekyll,backendeveloper/jekyll,winndows/jekyll,jmepg/jekyll,dangaute/eng,dezon/jekyll,gencer/jekyll,CheekyFE/jekyll,imaustink/jekyll,drobati/jekyll,darwin/jekyll,saitodisse/jekyll,tareq-s/jekyll,MauroMrod/jekyll,x-way/jekyll,hubsaysnuaa/jekyll,mnuessler/jekyll,xcatliu/jekyllcn,shliujing/jekyll,naughtyboy83/jekyll,fengsmith/jekyllcn,jmhardison/jekyll,martynbm/jekyll,Tyrion22/jekyll,matuzo/jekyll,CorainChicago/jekyll,dansef/jekyll,fengsmith/jekyll,Tiger66639/jekyll,nickg33/jekyll,indraj/jekyll,dangaute/eng,LeuisKen/jekyllcn,matuzo/jekyll,hartmel/jekyll,jmknoll/jekyll,AnanthaRajuC/jekyll,hubsaysnuaa/jekyll,leichunxin/jekyll,rajrathore/jekyll,superve/jekyll,tareq-s/jekyll,howkj1/jekyll,foocoder/jekyll,zsyed91/jekyll,teju111/jekyll,ZDroid/jekyll,eninya/jekyll,rlugojr/jekyll,alex-kovac/jekyll,kuangyeheng/jekyll,imaustink/jekyll,cyberid41/jekyll,ducktyper/jekyll,ls2uper/jekyll,x-way/jekyll,goragod/jekyll,gaosboy/jekyll,drobati/jekyll,tamouse/jekyll,codeclimate-testing/jekyll,xtymichael/jekyll,jaybe-jekyll/jekyll,ajhit406/jekyll,noikiy/jekyll,naughtyboy83/jekyll,LuoPX-15510486969/jekyll,QuinntyneBrown/jekyll,ramoslin02/jekyll,alex-kovac/jekyll,FlyingWHR/jekyll,xiebinhqy/jklly_china,yihangho/jekyll,18F/jekyll,ZDroid/jekyll,xiaoshaozi52/jekyll,SQS2/Test,rongl/jekyll,nemotan/jekyll,ryanshaw/jekyll,AnanthaRajuC/jekyll,nasht00/jekyll,tomjohnson1492/jekyll,18F/jekyll,abhilashhb/jekyll,gynter/jekyll,digideskio/jekyll,nasht00/jekyll,kuangyeheng/jekyll,trungvothanh/jekyll,vcgato29/jekyll,oresmus/jekyll,krishnakalyan3/jekyll,fulldecent/jekyll,Wirachmat/jekyll,krahman/jekyll,darwin/jekyll,julienbourdeau/jekyll,alfredxing/jekyll,krishnakalyan3/jekyll,egobrightan/jekyll,zsyed91/jekyll,marrujoalex/jekyll,jmptrader/jekyll,zhangkuaiji/jekyllcn,Teino1978-Corp/jekyll,jeffkole/jekyll,FlyingWHR/jekyll,thetaxman/jekyll,hubsaysnuaa/jekyll,18F/jekyll,floydpraveen/jekyll,jaybe-jekyll/jekyll,wadaries/jekyll,UniFreak/jekyllcn,ryanshaw/jekyll,doubleday/jekyll,floydpraveen/jekyll,harrissoerja/jekyll,htmelvis/jekyll,angeliaz/jekyll,gencer/jekyll,MjAbuz/jekyll,harrissoerja/jekyll,richsoni/jekyll,teju111/jekyll,gkunwar/gkunwar.github.io,indraj/jekyll,brint/jekyll,leichunxin/jekyll,chiyodad/jekyll,larryfox/jekyll,eloyesp/jekyll,daniel-beck/jekyll,dezon/jekyll,floydpraveen/jekyll,Wirachmat/jekyll,omeripek/jekyll,cyberid41/jekyll,AaronSikes/jekyll,goragod/jekyll,johnnycastilho/jekyll,marrujoalex/jekyll,AaronSikes/jekyll,isathish/jekyll,nathanhorrigan1/webdeveloper,fabulousu/jekyll,FlyingWHR/jekyll,doubleday/jekyll,mrb/jekyll,Teino1978-Corp/jekyll,tobscure/jekyll,CheekyFE/jekyll,iRoxx/jekyll,bsmr-ruby/jekyll,aarvay/jekyll,likong/jekyll,fengsmith/jekyll,foocoder/jekyll,jekyll/jekyll,xantage/jekyll,princeofdarkness76/jekyll,alihalabyah/jekyll,mrb/jekyll,aarvay/jekyll,jeffkole/jekyll,tillgrallert/jekyll,vidbina/jekyll,alfredxing/jekyll,jmhardison/jekyll,kimeng/jekyll,krahman/jekyll,ryanshaw/jekyll,sanxore/sanxore.github.com,Teino1978-Corp/Teino1978-Corp-jekyll,fengsmith/jekyllcn,supriyantomaftuh/jekyll,QuinntyneBrown/jekyll,pmarsceill/jekyll,pheuko/jekyll,m2candre/jekyll,CPVPLachlan/CPVP-Blog,MauroMrod/jekyll,omeripek/jekyll,yihangho/jekyll,SQS2/Test,tomjohnson1492/jekyll,greent2008/jekyll,xiebinhqy/jklly_china,xtymichael/jekyll,ZDroid/jekyll,hiteshsuthar/jekyll,ReachingOut/jekyll,xcatliu/jekyllcn,vcgato29/jekyll,derekgottlieb/jekyll,nathanhorrigan1/webdeveloper,htmelvis/jekyll,nathanhorrigan1/webdeveloper,honger05/jekyllcn,dezon/jekyll,getandpost/jekyll.github.io,ramoslin02/jekyll,ewinkler/jekyll,dansef/jekyll,pmarsceill/jekyll,oresmus/jekyll,wentixiaogege/jekyll,garvitr/jekyll,AtekiRyu/jekyll,AnanthaRajuC/jekyll,alex-kovac/jekyll,abhilashhb/jekyll,penchan1218/jekyllcn,stomar/jekyll,alex-kovac/jekyll,krishnakalyan3/jekyll,anthonyrosengren/grasshoppergathering2.github-io,Kinghack/kinghack.github.com,foocoder/jekyll,wadaries/jekyll,sanxore/sanxore.github.com,tylermachen/jekyll,tillgrallert/jekyll,harrissoerja/jekyll,garvitr/jekyll,noikiy/jekyll,vidbina/jekyll,greent2008/jekyll,UniFreak/jekyllcn,tillgrallert/jekyll,pmarsceill/jekyll,supriyantomaftuh/jekyll,matuzo/jekyll,likong/jekyll,alfredxing/jekyll,mixxmac/jekyll,x-way/jekyll,ramoslin02/jekyll,Strangehill/jekyll,sasongkojati/jekyll,jmknoll/jekyll,chrisfinazzo/jekyll,x-way/jekyll,ReachingOut/jekyll,mrb/jekyll,anthonyrosengren/grasshoppergathering2.github-io,winndows/jekyll,ryanshaw/jekyll,nickg33/jekyll,rajrathore/jekyll,iRoxx/jekyll,EddieDow/jekyll,wadaries/jekyll,tomjohnson1492/jekyll,howkj1/jekyll,AtekiRyu/jekyll,honger05/jekyllcn,xiaoshaozi52/jekyll,superve/jekyll,adilapapaya/jekyll,wentixiaogege/jekyll,pheuko/jekyll,thejameskyle/jekyll,bsmr-ruby/jekyll,ZainRizvi/jekyll,ls2uper/jekyll,darwin/jekyll,zsyed91/jekyll,zhangkuaiji/jekyllcn,stomar/jekyll,vcgato29/jekyll,digideskio/jekyll,nemotan/jekyll,gencer/jekyll,honger05/jekyllcn,angeliaz/jekyll,Strangehill/jekyll,tylermachen/jekyll,liukaijv/jekyll,jmptrader/jekyll,dansef/jekyll,yihangho/jekyll,CheekyFE/jekyll,thejameskyle/jekyll,jaroot32/jekyll,hartmel/jekyll,m2candre/jekyll,krahman/jekyll,tobscure/jekyll,Tyrion22/jekyll,saitodisse/jekyll,htmelvis/jekyll,MauroMrod/jekyll,rlugojr/jekyll,rebornix/jekyll,omeripek/jekyll,desidude03/jekyll,chrisfinazzo/jekyll,gencer/jekyll,SQS2/Test,derekgottlieb/jekyll,ZainRizvi/jekyll,Teino1978-Corp/jekyll,xiebinhqy/jklly_china,leichunxin/jekyll,christophermanning/jekyll,xantage/jekyll,julienbourdeau/jekyll,jeffkole/jekyll,tillgrallert/jekyll,alihalabyah/jekyll,martynbm/jekyll,CorainChicago/jekyll,Strangehill/jekyll,eloyesp/jekyll,QuinntyneBrown/jekyll,richsoni/jekyll,jekyll/jekyll,tomasdiez/jekyll,xcatliu/jekyllcn,royalwang/jekyll,penchan1218/jekyllcn,Kinghack/kinghack.github.com,jmknoll/jekyll,isathish/jekyll,pmarsceill/jekyll,gencer/jekyll,gynter/jekyll,gaosboy/jekyll,bsmr-ruby/jekyll,0x00evil/jekyll,Teino1978-Corp/Teino1978-Corp-jekyll,codeclimate-testing/jekyll,greent2008/jekyll,xiongjungit/jekyll,gkunwar/gkunwar.github.io,cyberid41/jekyll,jaroot32/jekyll,derekgottlieb/jekyll,0x00evil/jekyll,shuber2/jekyll,fengsmith/jekyll,nasht00/jekyll,AtekiRyu/jekyll,drobati/jekyll,abhilashhb/jekyll,pheuko/jekyll,xiaoshaozi52/jekyll,gynter/jekyll,UniFreak/jekyllcn,trungvothanh/jekyll,howkj1/jekyll,zhangkuaiji/jekyllcn,supriyantomaftuh/jekyll,shuber2/jekyll,ls2uper/jekyll,kuangyeheng/jekyll,nateberkopec/jekyll,jekyll/jekyll,daniel-beck/jekyll,thetaxman/jekyll,jmepg/jekyll,chiyodad/jekyll,LuoPX-15510486969/jekyll,hiteshsuthar/jekyll,ewinkler/jekyll,goragod/jekyll,mrb/jekyll,rebornix/jekyll,tomjohnson1492/jekyll,tobscure/jekyll,rebornix/jekyll,martynbm/jekyll,egobrightan/jekyll,sanxore/sanxore.github.com,jmepg/jekyll,rovrevik/jekyll,chinayin/jekyll,garvitr/jekyll,Strangehill/jekyll,ducktyper/jekyll,saitodisse/jekyll,shuber2/jekyll,shliujing/jekyll,daniel-beck/jekyll,tugberkugurlu/jekyll,mixxmac/jekyll,gaosboy/jekyll,egobrightan/jekyll,m2candre/jekyll,CPVPLachlan/CPVP-Blog,rlugojr/jekyll,doubleday/jekyll,noikiy/jekyll,jmhardison/jekyll,winndows/jekyll,liukaijv/jekyll,rlugojr/jekyll,EddieDow/jekyll,getandpost/jekyll.github.io,rasa2011/rasa2011.github.io,ReachingOut/jekyll,mnuessler/jekyll,CorainChicago/jekyll,hiteshsuthar/jekyll,rovrevik/jekyll,johnnycastilho/jekyll,ewinkler/jekyll,tamouse/jekyll,floydpraveen/jekyll,fabulousu/jekyll,christophermanning/jekyll,johnnycastilho/jekyll,alex-kovac/jekyll,superve/jekyll,rasa2011/rasa2011.github.io,chiyodad/jekyll,getandpost/jekyll.github.io,chinayin/jekyll
html
## Code Before: --- layout: default --- <section class="docs"> <div class="grid"> {% include docs_contents_mobile.html %} <div class="unit four-fifths"> <article> <div class="improve right"> <a href="https://github.com/jekyll/jekyll/edit/master/site/{{ page.path }}">Improve this page <i class="fa fa-pencil"></i></a> </div> <h1>{{ page.title }}</h1> {{ content }} {% include section_nav.html %} </article> </div> {% include docs_contents.html %} <div class="clear"></div> </div> </section> ## Instruction: Put the pencil icon in front of the improve link. Signed-off-by: Martin Jorn Rogalla <[email protected]> ## Code After: --- layout: default --- <section class="docs"> <div class="grid"> {% include docs_contents_mobile.html %} <div class="unit four-fifths"> <article> <div class="improve right"> <a href="https://github.com/jekyll/jekyll/edit/master/site/{{ page.path }}"><i class="fa fa-pencil"></i> &nbsp;Improve this page</a> </div> <h1>{{ page.title }}</h1> {{ content }} {% include section_nav.html %} </article> </div> {% include docs_contents.html %} <div class="clear"></div> </div> </section>
ca07dba85830fbd2dbc745779a67afabc74bd9df
app/views/messages/create.js.erb
app/views/messages/create.js.erb
<% if @message.persisted? %> var data = { success : true, statusMessage : '<%=j @notification[:notice].html_safe %>', sentMessage : '<%=j render "shared/message_list", message: @message.claim %>' } adp.messaging.processMsg(data); <% unless Claim::VALID_STATES_FOR_REDETERMINATION.include?(@message.claim.state) %> $('.claim-action-dropdown').hide(); <% end %> <% unless @message.claim.written_reasons_outstanding? %> $('.written-reasons-checkbox').hide(); <% end %> <% else %> var data ={ success : false, statusMessage : '<%=j @notification[:alert].html_safe %>' } adp.messaging.processMsg(data); <% end %>
<% if @message.persisted? %> var data = { success : true, statusMessage : '<%=j @notification[:notice].html_safe %>', sentMessage : '<%=j render "shared/message_list", message: @message.claim %>' } adp.messaging.processMsg(data); <% unless Claim::VALID_STATES_FOR_REDETERMINATION.include?(@message.claim.state) %> $('.js-hide-status').hide(); <% end %> <% unless @message.claim.written_reasons_outstanding? %> $('.written-reasons-checkbox').hide(); <% end %> <% else %> var data ={ success : false, statusMessage : '<%=j @notification[:alert].html_safe %>' } adp.messaging.processMsg(data); <% end %>
Hide the status update section if they have send it as part of the message
Hide the status update section if they have send it as part of the message
HTML+ERB
mit
ministryofjustice/advocate-defence-payments,ministryofjustice/advocate-defence-payments,ministryofjustice/advocate-defence-payments,ministryofjustice/advocate-defence-payments
html+erb
## Code Before: <% if @message.persisted? %> var data = { success : true, statusMessage : '<%=j @notification[:notice].html_safe %>', sentMessage : '<%=j render "shared/message_list", message: @message.claim %>' } adp.messaging.processMsg(data); <% unless Claim::VALID_STATES_FOR_REDETERMINATION.include?(@message.claim.state) %> $('.claim-action-dropdown').hide(); <% end %> <% unless @message.claim.written_reasons_outstanding? %> $('.written-reasons-checkbox').hide(); <% end %> <% else %> var data ={ success : false, statusMessage : '<%=j @notification[:alert].html_safe %>' } adp.messaging.processMsg(data); <% end %> ## Instruction: Hide the status update section if they have send it as part of the message ## Code After: <% if @message.persisted? %> var data = { success : true, statusMessage : '<%=j @notification[:notice].html_safe %>', sentMessage : '<%=j render "shared/message_list", message: @message.claim %>' } adp.messaging.processMsg(data); <% unless Claim::VALID_STATES_FOR_REDETERMINATION.include?(@message.claim.state) %> $('.js-hide-status').hide(); <% end %> <% unless @message.claim.written_reasons_outstanding? %> $('.written-reasons-checkbox').hide(); <% end %> <% else %> var data ={ success : false, statusMessage : '<%=j @notification[:alert].html_safe %>' } adp.messaging.processMsg(data); <% end %>
6740467a15a54d4ca0bf0a7e358e2e5c92e04344
setup.py
setup.py
from setuptools import setup, find_packages import re VERSIONFILE = "openomni/_version.py" verstrline = open(VERSIONFILE, "rt").read() VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" mo = re.search(VSRE, verstrline, re.M) if mo: verstr = mo.group(1) else: raise RuntimeError("Unable to find version string in %s." % (VERSIONFILE,)) setup(name='openomni', version=verstr, description='Omnipod Packet Decoding Library', url='http://github.com/openaps/omni', # See https://github.com/openaps/openomni/graphs/contributors for actual # contributors... author='Pete Schwamb', author_email='[email protected]', scripts=[ 'openomni/bin/decode_omni', 'openomni/bin/omni_listen_rfcat', 'openomni/bin/omni_akimbo', 'openomni/bin/omni_explore', 'openomni/bin/omni_send_rfcat', 'openomni/bin/omni_forloop'], packages=find_packages(), install_requires=[ 'crccheck', ], zip_safe=False)
from setuptools import setup, find_packages import re VERSIONFILE = "openomni/_version.py" verstrline = open(VERSIONFILE, "rt").read() VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" mo = re.search(VSRE, verstrline, re.M) if mo: verstr = mo.group(1) else: raise RuntimeError("Unable to find version string in %s." % (VERSIONFILE,)) setup(name='openomni', version=verstr, description='Omnipod Packet Decoding Library', url='http://github.com/openaps/omni', # See https://github.com/openaps/openomni/graphs/contributors for actual # contributors... author='Pete Schwamb', author_email='[email protected]', scripts=[ 'openomni/bin/decode_omni', 'openomni/bin/omni_listen_rfcat', 'openomni/bin/omni_akimbo', 'openomni/bin/omni_explore', 'openomni/bin/omni_send_rfcat', 'openomni/bin/omni_forloop'], packages=find_packages(), install_requires=[ 'crccheck', 'enum34;python_version<"3.4"', ], zip_safe=False)
Install enum34 if not provided
Install enum34 if not provided
Python
mit
openaps/openomni,openaps/openomni,openaps/openomni
python
## Code Before: from setuptools import setup, find_packages import re VERSIONFILE = "openomni/_version.py" verstrline = open(VERSIONFILE, "rt").read() VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" mo = re.search(VSRE, verstrline, re.M) if mo: verstr = mo.group(1) else: raise RuntimeError("Unable to find version string in %s." % (VERSIONFILE,)) setup(name='openomni', version=verstr, description='Omnipod Packet Decoding Library', url='http://github.com/openaps/omni', # See https://github.com/openaps/openomni/graphs/contributors for actual # contributors... author='Pete Schwamb', author_email='[email protected]', scripts=[ 'openomni/bin/decode_omni', 'openomni/bin/omni_listen_rfcat', 'openomni/bin/omni_akimbo', 'openomni/bin/omni_explore', 'openomni/bin/omni_send_rfcat', 'openomni/bin/omni_forloop'], packages=find_packages(), install_requires=[ 'crccheck', ], zip_safe=False) ## Instruction: Install enum34 if not provided ## Code After: from setuptools import setup, find_packages import re VERSIONFILE = "openomni/_version.py" verstrline = open(VERSIONFILE, "rt").read() VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" mo = re.search(VSRE, verstrline, re.M) if mo: verstr = mo.group(1) else: raise RuntimeError("Unable to find version string in %s." % (VERSIONFILE,)) setup(name='openomni', version=verstr, description='Omnipod Packet Decoding Library', url='http://github.com/openaps/omni', # See https://github.com/openaps/openomni/graphs/contributors for actual # contributors... author='Pete Schwamb', author_email='[email protected]', scripts=[ 'openomni/bin/decode_omni', 'openomni/bin/omni_listen_rfcat', 'openomni/bin/omni_akimbo', 'openomni/bin/omni_explore', 'openomni/bin/omni_send_rfcat', 'openomni/bin/omni_forloop'], packages=find_packages(), install_requires=[ 'crccheck', 'enum34;python_version<"3.4"', ], zip_safe=False)
4e8a2bc0729fa48634940fdd4924ccd80ff39571
.travis.yml
.travis.yml
install: - sudo apt-get update - sudo apt-get install texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended texlive-science texlive-bibtex-extra - sudo apt-get install chktex latexmk script: - latexmk masterthesis - latexmk presentation #- chktex -q -n 6 *.tex **/*.tex 2>/dev/null | tee lint.out #- test ! -s lint.out
install: - sudo apt-get update - sudo apt-get install texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended texlive-science texlive-bibtex-extra - sudo apt-get install latexmk #- sudo apt-get install chktex script: - latexmk masterthesis - latexmk presentation #- chktex -q -n 6 *.tex **/*.tex 2>/dev/null | tee lint.out #- test ! -s lint.out
Move chktex to separate install command and comment it out as we are not using chktext at the moment.
Move chktex to separate install command and comment it out as we are not using chktext at the moment.
YAML
mit
fladi/CAMPUS02-LaTeX
yaml
## Code Before: install: - sudo apt-get update - sudo apt-get install texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended texlive-science texlive-bibtex-extra - sudo apt-get install chktex latexmk script: - latexmk masterthesis - latexmk presentation #- chktex -q -n 6 *.tex **/*.tex 2>/dev/null | tee lint.out #- test ! -s lint.out ## Instruction: Move chktex to separate install command and comment it out as we are not using chktext at the moment. ## Code After: install: - sudo apt-get update - sudo apt-get install texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended texlive-science texlive-bibtex-extra - sudo apt-get install latexmk #- sudo apt-get install chktex script: - latexmk masterthesis - latexmk presentation #- chktex -q -n 6 *.tex **/*.tex 2>/dev/null | tee lint.out #- test ! -s lint.out
51a70b67f4c33218bfcb3b3fa64eaea396bfc026
app/views/tabs/_profile.html.haml
app/views/tabs/_profile.html.haml
.card .list-group.list-group-horizontal-sm.text-center = list_group_item t(".answers"), user_path(user), badge: user.answered_count = list_group_item t(".questions"), show_user_questions_path(user.screen_name), badge: user.asked_count = list_group_item t(".followers"), show_user_followers_path(user.screen_name), badge: user.followers.count = list_group_item t(".following"), show_user_followings_path(user.screen_name), badge: user.followings.count
.card .list-group.list-group-horizontal-sm.text-center = list_group_item t(".answers"), user_path(user), badge: user.answered_count = list_group_item t(".questions"), show_user_questions_path(user.screen_name), badge: user.asked_count - if user == current_user || !user.privacy_hide_social_graph = list_group_item t(".followers"), show_user_followers_path(user.screen_name), badge: user.followers.count = list_group_item t(".following"), show_user_followings_path(user.screen_name), badge: user.followings.count
Hide follower/followings tabs if social graph is hidden
Hide follower/followings tabs if social graph is hidden
Haml
agpl-3.0
Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring
haml
## Code Before: .card .list-group.list-group-horizontal-sm.text-center = list_group_item t(".answers"), user_path(user), badge: user.answered_count = list_group_item t(".questions"), show_user_questions_path(user.screen_name), badge: user.asked_count = list_group_item t(".followers"), show_user_followers_path(user.screen_name), badge: user.followers.count = list_group_item t(".following"), show_user_followings_path(user.screen_name), badge: user.followings.count ## Instruction: Hide follower/followings tabs if social graph is hidden ## Code After: .card .list-group.list-group-horizontal-sm.text-center = list_group_item t(".answers"), user_path(user), badge: user.answered_count = list_group_item t(".questions"), show_user_questions_path(user.screen_name), badge: user.asked_count - if user == current_user || !user.privacy_hide_social_graph = list_group_item t(".followers"), show_user_followers_path(user.screen_name), badge: user.followers.count = list_group_item t(".following"), show_user_followings_path(user.screen_name), badge: user.followings.count
f2a1361a6139aff865f0a515512ec0c544948fe7
git/gitconfig.erb
git/gitconfig.erb
[user] name = Francisco J. email = [email protected] [color] diff = auto status = auto branch = auto [core] excludesfile = <%= ENV['HOME'] %>/.gitignore editor = "/usr/local/bin/mvim -f" autocrlf = input [apply] whitespace = fix [format] pretty = %C(yellow)%h%Creset %s %C(red)(%cr)%Creset [alias] co = checkout s = status [github] user = franciscoj token = <%= print("GitHub API Token: "); STDOUT.flush; STDIN.gets.chomp %>
[user] name = Francisco J. email = [email protected] [color] diff = auto status = auto branch = auto [core] excludesfile = <%= ENV['HOME'] %>/.gitignore editor = "/usr/local/bin/mvim -f" autocrlf = input [apply] whitespace = fix [format] pretty = %C(yellow)%h%Creset %s %C(red)(%cr)%Creset [alias] co = checkout s = status [github] user = franciscoj token = <%= print("GitHub API Token: "); STDOUT.flush; STDIN.gets.chomp %> [merge] tool = vimdiff
Set vimdiff as the default mergetool
Set vimdiff as the default mergetool
HTML+ERB
mit
franciscoj/dot-files,franciscoj/dot-files,franciscoj/dot-files
html+erb
## Code Before: [user] name = Francisco J. email = [email protected] [color] diff = auto status = auto branch = auto [core] excludesfile = <%= ENV['HOME'] %>/.gitignore editor = "/usr/local/bin/mvim -f" autocrlf = input [apply] whitespace = fix [format] pretty = %C(yellow)%h%Creset %s %C(red)(%cr)%Creset [alias] co = checkout s = status [github] user = franciscoj token = <%= print("GitHub API Token: "); STDOUT.flush; STDIN.gets.chomp %> ## Instruction: Set vimdiff as the default mergetool ## Code After: [user] name = Francisco J. email = [email protected] [color] diff = auto status = auto branch = auto [core] excludesfile = <%= ENV['HOME'] %>/.gitignore editor = "/usr/local/bin/mvim -f" autocrlf = input [apply] whitespace = fix [format] pretty = %C(yellow)%h%Creset %s %C(red)(%cr)%Creset [alias] co = checkout s = status [github] user = franciscoj token = <%= print("GitHub API Token: "); STDOUT.flush; STDIN.gets.chomp %> [merge] tool = vimdiff
e3820943985466929d430b0e40975cea06915f36
app/admin/api_key.rb
app/admin/api_key.rb
ActiveAdmin.register ApiKey do index do column :id column :access_token default_actions end filter :access_token show do |user| attributes_table do row :id row :access_token end active_admin_comments end form do |f| f.actions end end
ActiveAdmin.register ApiKey do index do column :id column :access_token default_actions end filter :access_token show do |user| attributes_table do row :id row :access_token end active_admin_comments end form do |f| unless f.object.new_record? f.inputs "Api Key Details" do f.input :access_token end end f.actions end end
Allow edit of access token in admin panel
Allow edit of access token in admin panel
Ruby
mit
mnipper/rails_survey,mnipper/rails_survey,mnipper/rails_survey
ruby
## Code Before: ActiveAdmin.register ApiKey do index do column :id column :access_token default_actions end filter :access_token show do |user| attributes_table do row :id row :access_token end active_admin_comments end form do |f| f.actions end end ## Instruction: Allow edit of access token in admin panel ## Code After: ActiveAdmin.register ApiKey do index do column :id column :access_token default_actions end filter :access_token show do |user| attributes_table do row :id row :access_token end active_admin_comments end form do |f| unless f.object.new_record? f.inputs "Api Key Details" do f.input :access_token end end f.actions end end
f636452fec9b2cff48ff680bc69308603b738d0b
recipes/gstreamer/gst-plugins-ugly_0.10.18.3.bb
recipes/gstreamer/gst-plugins-ugly_0.10.18.3.bb
require gst-plugins.inc SRC_URI = "http://gstreamer.freedesktop.org/src/${PN}/pre/${PN}-${PV}.tar.bz2;name=archive" #SRC_URI_append_sifteam = " file://dvdsubdec-addproperty-singlebuffer.patch" PR = "${INC_PR}.0" DEPENDS += "gst-plugins-base libsidplay" DEPENDS_sifteam += "gst-plugins-base libsidplay opencore-amr" python() { # Don't build, if we are building an ENTERPRISE distro enterprise = bb.data.getVar("ENTERPRISE_DISTRO", d, 1) if enterprise == "1": raise bb.parse.SkipPackage("gst-plugins-ugly will only build if ENTERPRISE_DISTRO != 1") } PACKAGES_DYNAMIC = "\ gst-plugin-a52dec.* \ gst-plugin-asf.* \ gst-plugin-cdio.* \ gst-plugin-dvdlpcmdec.* \ gst-plugin-dvdread.* \ gst-plugin-dvdsub.* \ gst-plugin-iec958.* \ gst-plugin-lame.* \ gst-plugin-mad.* \ gst-plugin-mpeg2dec.* \ gst-plugin-mpegaudioparse.* \ gst-plugin-mpegstream.* \ gst-plugin-rmdemux.* \ gst-plugin-sid.* \ gst-plugin-x264.* \ "
require gst-plugins.inc SRC_URI = "http://gstreamer.freedesktop.org/src/${PN}/pre/${PN}-${PV}.tar.bz2;name=archive" #SRC_URI_append_sifteam = " file://dvdsubdec-addproperty-singlebuffer.patch" PR = "${INC_PR}.0" DEPENDS += "gst-plugins-base libsidplay" DEPENDS_sifteam += "gst-plugins-base libsidplay opencore-amr" python() { # Don't build, if we are building an ENTERPRISE distro enterprise = bb.data.getVar("ENTERPRISE_DISTRO", d, 1) if enterprise == "1": raise bb.parse.SkipPackage("gst-plugins-ugly will only build if ENTERPRISE_DISTRO != 1") } PACKAGES_DYNAMIC = "\ gst-plugin-a52dec.* \ gst-plugin-asf.* \ gst-plugin-cdio.* \ gst-plugin-dvdlpcmdec.* \ gst-plugin-dvdread.* \ gst-plugin-dvdsub.* \ gst-plugin-iec958.* \ gst-plugin-lame.* \ gst-plugin-mad.* \ gst-plugin-mpeg2dec.* \ gst-plugin-mpegaudioparse.* \ gst-plugin-mpegstream.* \ gst-plugin-rmdemux.* \ gst-plugin-sid.* \ gst-plugin-x264.* \ gst-plugin-amrnb.* \ gst-plugin-amrwbdec.* \ "
Fix gst-plugins-ugly for amr coded
Fix gst-plugins-ugly for amr coded
BitBake
mit
SIFTeam/openembedded,SIFTeam/openembedded,SIFTeam/openembedded,SIFTeam/openembedded,SIFTeam/openembedded,SIFTeam/openembedded,SIFTeam/openembedded
bitbake
## Code Before: require gst-plugins.inc SRC_URI = "http://gstreamer.freedesktop.org/src/${PN}/pre/${PN}-${PV}.tar.bz2;name=archive" #SRC_URI_append_sifteam = " file://dvdsubdec-addproperty-singlebuffer.patch" PR = "${INC_PR}.0" DEPENDS += "gst-plugins-base libsidplay" DEPENDS_sifteam += "gst-plugins-base libsidplay opencore-amr" python() { # Don't build, if we are building an ENTERPRISE distro enterprise = bb.data.getVar("ENTERPRISE_DISTRO", d, 1) if enterprise == "1": raise bb.parse.SkipPackage("gst-plugins-ugly will only build if ENTERPRISE_DISTRO != 1") } PACKAGES_DYNAMIC = "\ gst-plugin-a52dec.* \ gst-plugin-asf.* \ gst-plugin-cdio.* \ gst-plugin-dvdlpcmdec.* \ gst-plugin-dvdread.* \ gst-plugin-dvdsub.* \ gst-plugin-iec958.* \ gst-plugin-lame.* \ gst-plugin-mad.* \ gst-plugin-mpeg2dec.* \ gst-plugin-mpegaudioparse.* \ gst-plugin-mpegstream.* \ gst-plugin-rmdemux.* \ gst-plugin-sid.* \ gst-plugin-x264.* \ " ## Instruction: Fix gst-plugins-ugly for amr coded ## Code After: require gst-plugins.inc SRC_URI = "http://gstreamer.freedesktop.org/src/${PN}/pre/${PN}-${PV}.tar.bz2;name=archive" #SRC_URI_append_sifteam = " file://dvdsubdec-addproperty-singlebuffer.patch" PR = "${INC_PR}.0" DEPENDS += "gst-plugins-base libsidplay" DEPENDS_sifteam += "gst-plugins-base libsidplay opencore-amr" python() { # Don't build, if we are building an ENTERPRISE distro enterprise = bb.data.getVar("ENTERPRISE_DISTRO", d, 1) if enterprise == "1": raise bb.parse.SkipPackage("gst-plugins-ugly will only build if ENTERPRISE_DISTRO != 1") } PACKAGES_DYNAMIC = "\ gst-plugin-a52dec.* \ gst-plugin-asf.* \ gst-plugin-cdio.* \ gst-plugin-dvdlpcmdec.* \ gst-plugin-dvdread.* \ gst-plugin-dvdsub.* \ gst-plugin-iec958.* \ gst-plugin-lame.* \ gst-plugin-mad.* \ gst-plugin-mpeg2dec.* \ gst-plugin-mpegaudioparse.* \ gst-plugin-mpegstream.* \ gst-plugin-rmdemux.* \ gst-plugin-sid.* \ gst-plugin-x264.* \ gst-plugin-amrnb.* \ gst-plugin-amrwbdec.* \ "
c899b074201064f5abe00639fd022c80eaf15e7f
timeblob/fixtures/debug.yaml
timeblob/fixtures/debug.yaml
- model: auth.User pk: 1 fields: username: john_lennon first_name: John last_name: Lennon
- model: auth.User pk: 1 fields: username: alice first_name: Alice last_name: TheAdmin #password=pass password: 'pbkdf2_sha256$30000$lBLLm7V2MUpC$t9BklF/Ds9AFAVTlAxe0GG10lNfUnZXu+TuVCAr4BRA='
Add in the alice fixture
Add in the alice fixture
YAML
agpl-3.0
dkieffer/timeblob,dkieffer/timeblob,dkieffer/timeblob,dkieffer/timeblob,dkieffer/timeblob,dkieffer/timeblob
yaml
## Code Before: - model: auth.User pk: 1 fields: username: john_lennon first_name: John last_name: Lennon ## Instruction: Add in the alice fixture ## Code After: - model: auth.User pk: 1 fields: username: alice first_name: Alice last_name: TheAdmin #password=pass password: 'pbkdf2_sha256$30000$lBLLm7V2MUpC$t9BklF/Ds9AFAVTlAxe0GG10lNfUnZXu+TuVCAr4BRA='
c1bd0df0d77e840d7b20f1e8decbd69c3b22e859
config/initializers/mail_config.rb
config/initializers/mail_config.rb
begin if Rails.env.production? ActionMailer::Base.smtp_settings = { address: 'smtp.mandrillapp.com', port: '587', authentication: :plain, user_name: Configuration[:mandrill_user_name], password: Configuration[:mandrill], domain: 'heroku.com' } ActionMailer::Base.delivery_method = :smtp end rescue nil end
begin ActionMailer::Base.default 'Content-Transfer-Encoding' => 'quoted-printable' if Rails.env.production? ActionMailer::Base.smtp_settings = { address: 'smtp.mandrillapp.com', port: '587', authentication: :plain, user_name: Configuration[:mandrill_user_name], password: Configuration[:mandrill], domain: 'heroku.com' } ActionMailer::Base.delivery_method = :smtp end rescue nil end
Add quoted-printable to ActionMailer Content-Transfer-Encoding
Add quoted-printable to ActionMailer Content-Transfer-Encoding
Ruby
mit
jinutm/silverclass,jinutm/silverpro,gustavoguichard/neighborly,jinutm/silverprod,rockkhuya/taydantay,jinutm/silverme,rockkhuya/taydantay,rockkhuya/taydantay,jinutm/silverclass,raksonibs/raimcrowd,MicroPasts/micropasts-crowdfunding,jinutm/silvfinal,raksonibs/raimcrowd,raksonibs/raimcrowd,jinutm/silverprod,jinutm/silverme,jinutm/silverpro,jinutm/silverpro,jinutm/silveralms.com,MicroPasts/micropasts-crowdfunding,jinutm/silvfinal,jinutm/silveralms.com,jinutm/silverclass,jinutm/silverme,raksonibs/raimcrowd,gustavoguichard/neighborly,MicroPasts/micropasts-crowdfunding,gustavoguichard/neighborly,jinutm/silverprod,MicroPasts/micropasts-crowdfunding,jinutm/silvfinal,jinutm/silveralms.com
ruby
## Code Before: begin if Rails.env.production? ActionMailer::Base.smtp_settings = { address: 'smtp.mandrillapp.com', port: '587', authentication: :plain, user_name: Configuration[:mandrill_user_name], password: Configuration[:mandrill], domain: 'heroku.com' } ActionMailer::Base.delivery_method = :smtp end rescue nil end ## Instruction: Add quoted-printable to ActionMailer Content-Transfer-Encoding ## Code After: begin ActionMailer::Base.default 'Content-Transfer-Encoding' => 'quoted-printable' if Rails.env.production? ActionMailer::Base.smtp_settings = { address: 'smtp.mandrillapp.com', port: '587', authentication: :plain, user_name: Configuration[:mandrill_user_name], password: Configuration[:mandrill], domain: 'heroku.com' } ActionMailer::Base.delivery_method = :smtp end rescue nil end
2a9c213c02abbabeddbf2a699fd6caf5e18bf6dd
utils/word_checking.py
utils/word_checking.py
from __future__ import unicode_literals import re from collections import Counter def check_for_flag_words(message, words_array): cnt = Counter() delims = '!"#$%&()*+,./:;<=>?@[\\]^_`{|}~\t\n\x0b\x0c\r ' pattern = r"[{}]".format(delims) message_array = re.split(pattern, message.lower()) for word in message_array: formatted_word = word.replace(u"\u2019s", "").replace(u"s\u2019", "s").replace("'s", "").replace("s'", "s") if formatted_word in words_array: cnt[formatted_word] += 1 return dict(cnt)
from __future__ import unicode_literals import re from collections import Counter def check_for_flag_words(message, words_array): cnt = Counter() delims = '!"#$%&()*+,./:;<=>?@[\\]^_`{|}~\t\n\x0b\x0c\r ' pattern = r"[{}]".format(delims) message_array = re.split(pattern, message.lower()) for word in message_array: # remove numbers from the word text_word = re.sub("\d", "", word) # handle apostrophes including unicode, ie. apple's -> apple and apples' -> apples formatted_word = text_word.replace(u"\u2019s", "").replace(u"s\u2019", "s").replace("'s", "").replace("s'", "s") if formatted_word in words_array: cnt[formatted_word] += 1 return dict(cnt)
Remove numbers from the word to check for.
Remove numbers from the word to check for.
Python
apache-2.0
jkvoorhis/cheeseburger_backpack_bot
python
## Code Before: from __future__ import unicode_literals import re from collections import Counter def check_for_flag_words(message, words_array): cnt = Counter() delims = '!"#$%&()*+,./:;<=>?@[\\]^_`{|}~\t\n\x0b\x0c\r ' pattern = r"[{}]".format(delims) message_array = re.split(pattern, message.lower()) for word in message_array: formatted_word = word.replace(u"\u2019s", "").replace(u"s\u2019", "s").replace("'s", "").replace("s'", "s") if formatted_word in words_array: cnt[formatted_word] += 1 return dict(cnt) ## Instruction: Remove numbers from the word to check for. ## Code After: from __future__ import unicode_literals import re from collections import Counter def check_for_flag_words(message, words_array): cnt = Counter() delims = '!"#$%&()*+,./:;<=>?@[\\]^_`{|}~\t\n\x0b\x0c\r ' pattern = r"[{}]".format(delims) message_array = re.split(pattern, message.lower()) for word in message_array: # remove numbers from the word text_word = re.sub("\d", "", word) # handle apostrophes including unicode, ie. apple's -> apple and apples' -> apples formatted_word = text_word.replace(u"\u2019s", "").replace(u"s\u2019", "s").replace("'s", "").replace("s'", "s") if formatted_word in words_array: cnt[formatted_word] += 1 return dict(cnt)
0549bb146a54cdd195f0b2a3519cc3811c69bb80
README.md
README.md
- Simpler is better. Resist overcomplexifying. Prefer duplication over imperfect abstraction. - HTML classes for CSS, JS, and test selection should be namespaced and kept strictly separate. For example, any class used for selecting elements in tests should start with `test-`. ## Todo - App renders times in terms of US EST; make this sensitive to where the user is
- Simpler is better. Resist overcomplexifying. Prefer duplication over imperfect abstraction. - HTML classes for CSS, JS, and test selection should be namespaced and kept strictly separate. For example, any class used for selecting elements in tests should start with `test-`. ## Todo - App renders times in terms of US EST; make this sensitive to where the user is ## Social media login Dashboards for managing settings: - https://console.developers.google.com/apis/credentials?project=integral-climate - https://developers.facebook.com/apps/1772130993029813/settings/ - [LinkedIn: Todo]
Update readme w social auth links
Update readme w social auth links
Markdown
mit
topherhunt/integral-climate-action,topherhunt/integral-climate-action,topherhunt/integral-climate-action
markdown
## Code Before: - Simpler is better. Resist overcomplexifying. Prefer duplication over imperfect abstraction. - HTML classes for CSS, JS, and test selection should be namespaced and kept strictly separate. For example, any class used for selecting elements in tests should start with `test-`. ## Todo - App renders times in terms of US EST; make this sensitive to where the user is ## Instruction: Update readme w social auth links ## Code After: - Simpler is better. Resist overcomplexifying. Prefer duplication over imperfect abstraction. - HTML classes for CSS, JS, and test selection should be namespaced and kept strictly separate. For example, any class used for selecting elements in tests should start with `test-`. ## Todo - App renders times in terms of US EST; make this sensitive to where the user is ## Social media login Dashboards for managing settings: - https://console.developers.google.com/apis/credentials?project=integral-climate - https://developers.facebook.com/apps/1772130993029813/settings/ - [LinkedIn: Todo]
adc930b31537909c50e4e648f316690e67ec63f7
apps/displays/Vrvana_Totem.json
apps/displays/Vrvana_Totem.json
{ "hmd": { "device": { "vendor": "Vrvana", "model": "Totem", "Version": "1" }, "field_of_view": { "monocular_horizontal": 105, "monocular_vertical": 111.41, "overlap_percent": 100, "pitch_tilt": 0 }, "resolutions": [{ "width": 2560, "height": 1440, "video_inputs": 1, "display_mode": "horz_side_by_side" }], "distortion": { "k1_red": 0, "k1_green": 0, "k1_blue": 0 }, "rendering": { "right_roll": 0, "left_roll": 0 }, "eyes": [{ "center_proj_x": 0.5, "center_proj_y": 0.5, "rotate_180": 0 }] } }
{ "meta": { "schemaVersion": 1 }, "hmd": { "device": { "vendor": "Vrvana", "model": "Totem", "Version": "1" }, "field_of_view": { "monocular_horizontal": 105, "monocular_vertical": 111.41, "overlap_percent": 100, "pitch_tilt": 0 }, "resolutions": [{ "width": 2560, "height": 1440, "video_inputs": 1, "display_mode": "horz_side_by_side" }], "distortion": { "k1_red": 0, "k1_green": 0, "k1_blue": 0 }, "rendering": { "right_roll": 0, "left_roll": 0 }, "eyes": [{ "center_proj_x": 0.5, "center_proj_y": 0.5, "rotate_180": 0 }] } }
Add schema version to Vrvana descriptor
Add schema version to Vrvana descriptor
JSON
apache-2.0
OSVR/OSVR-Core,d235j/OSVR-Core,Armada651/OSVR-Core,OSVR/OSVR-Core,OSVR/OSVR-Core,feilen/OSVR-Core,d235j/OSVR-Core,d235j/OSVR-Core,feilen/OSVR-Core,leemichaelRazer/OSVR-Core,leemichaelRazer/OSVR-Core,OSVR/OSVR-Core,godbyk/OSVR-Core,feilen/OSVR-Core,Armada651/OSVR-Core,feilen/OSVR-Core,godbyk/OSVR-Core,godbyk/OSVR-Core,d235j/OSVR-Core,OSVR/OSVR-Core,Armada651/OSVR-Core,d235j/OSVR-Core,leemichaelRazer/OSVR-Core,leemichaelRazer/OSVR-Core,godbyk/OSVR-Core,Armada651/OSVR-Core,leemichaelRazer/OSVR-Core,godbyk/OSVR-Core,godbyk/OSVR-Core,Armada651/OSVR-Core,OSVR/OSVR-Core,feilen/OSVR-Core
json
## Code Before: { "hmd": { "device": { "vendor": "Vrvana", "model": "Totem", "Version": "1" }, "field_of_view": { "monocular_horizontal": 105, "monocular_vertical": 111.41, "overlap_percent": 100, "pitch_tilt": 0 }, "resolutions": [{ "width": 2560, "height": 1440, "video_inputs": 1, "display_mode": "horz_side_by_side" }], "distortion": { "k1_red": 0, "k1_green": 0, "k1_blue": 0 }, "rendering": { "right_roll": 0, "left_roll": 0 }, "eyes": [{ "center_proj_x": 0.5, "center_proj_y": 0.5, "rotate_180": 0 }] } } ## Instruction: Add schema version to Vrvana descriptor ## Code After: { "meta": { "schemaVersion": 1 }, "hmd": { "device": { "vendor": "Vrvana", "model": "Totem", "Version": "1" }, "field_of_view": { "monocular_horizontal": 105, "monocular_vertical": 111.41, "overlap_percent": 100, "pitch_tilt": 0 }, "resolutions": [{ "width": 2560, "height": 1440, "video_inputs": 1, "display_mode": "horz_side_by_side" }], "distortion": { "k1_red": 0, "k1_green": 0, "k1_blue": 0 }, "rendering": { "right_roll": 0, "left_roll": 0 }, "eyes": [{ "center_proj_x": 0.5, "center_proj_y": 0.5, "rotate_180": 0 }] } }
93a26130193277d108eae198661b9ead6004bd31
src/Image/Transformation/Clip.php
src/Image/Transformation/Clip.php
<?php /** * This file is part of the Imbo package * * (c) Christer Edvartsen <[email protected]> * * For the full copyright and license information, please view the LICENSE file that was * distributed with this source code. */ namespace Imbo\Image\Transformation; use Imbo\Exception\TransformationException, ImagickException; /** * Clip transformation * * @author Mats Lindh <[email protected]> * @package Image\Transformations */ class Clip extends Transformation { /** * {@inheritdoc} */ public function transform(array $params) { try { $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_TRANSPARENT); $this->imagick->clipImage(); $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_OPAQUE); } catch (ImagickException $e) { throw new TransformationException($e->getMessage(), 400, $e); } $this->image->hasBeenTransformed(true); } }
<?php /** * This file is part of the Imbo package * * (c) Christer Edvartsen <[email protected]> * * For the full copyright and license information, please view the LICENSE file that was * distributed with this source code. */ namespace Imbo\Image\Transformation; use Imbo\Exception\TransformationException, ImagickException; /** * Clip transformation * * @author Mats Lindh <[email protected]> * @package Image\Transformations */ class Clip extends Transformation { /** * {@inheritdoc} */ public function transform(array $params) { try { $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_TRANSPARENT); $this->imagick->clipImage(); $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_OPAQUE); } catch (ImagickException $e) { // NoClipPathDefined - the image doesn't have a clip path, but this isn't an fatal error. if ($e->getCode() == 410) { return; } throw new TransformationException($e->getMessage(), 400, $e); } $this->image->hasBeenTransformed(true); } }
Handle files without a clip path
Handle files without a clip path
PHP
mit
imbo/imbo,imbo/imbo,matslindh/imbo,matslindh/imbo,TV2/imbo,TV2/imbo
php
## Code Before: <?php /** * This file is part of the Imbo package * * (c) Christer Edvartsen <[email protected]> * * For the full copyright and license information, please view the LICENSE file that was * distributed with this source code. */ namespace Imbo\Image\Transformation; use Imbo\Exception\TransformationException, ImagickException; /** * Clip transformation * * @author Mats Lindh <[email protected]> * @package Image\Transformations */ class Clip extends Transformation { /** * {@inheritdoc} */ public function transform(array $params) { try { $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_TRANSPARENT); $this->imagick->clipImage(); $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_OPAQUE); } catch (ImagickException $e) { throw new TransformationException($e->getMessage(), 400, $e); } $this->image->hasBeenTransformed(true); } } ## Instruction: Handle files without a clip path ## Code After: <?php /** * This file is part of the Imbo package * * (c) Christer Edvartsen <[email protected]> * * For the full copyright and license information, please view the LICENSE file that was * distributed with this source code. */ namespace Imbo\Image\Transformation; use Imbo\Exception\TransformationException, ImagickException; /** * Clip transformation * * @author Mats Lindh <[email protected]> * @package Image\Transformations */ class Clip extends Transformation { /** * {@inheritdoc} */ public function transform(array $params) { try { $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_TRANSPARENT); $this->imagick->clipImage(); $this->imagick->setImageAlphaChannel(\Imagick::ALPHACHANNEL_OPAQUE); } catch (ImagickException $e) { // NoClipPathDefined - the image doesn't have a clip path, but this isn't an fatal error. if ($e->getCode() == 410) { return; } throw new TransformationException($e->getMessage(), 400, $e); } $this->image->hasBeenTransformed(true); } }
c128d4f6c1346d1ad5456c420a4b177e8a81b7fb
db/migrate/1_create_retailers_retailers.rb
db/migrate/1_create_retailers_retailers.rb
class CreateRetailersRetailers < ActiveRecord::Migration def up create_table :refinery_retailers do |t| t.string :title t.string :contact t.string :address t.string :zipcode t.string :phone t.string :fax t.string :email t.string :website t.boolean :draft t.integer :position t.timestamps end end def down if defined?(::Refinery::UserPlugin) ::Refinery::UserPlugin.destroy_all({:name => "refinerycms-retailers"}) end if defined?(::Refinery::Page) ::Refinery::Page.delete_all({:link_url => "/retailers/retailers"}) end drop_table :refinery_retailers end end
class CreateRetailersRetailers < ActiveRecord::Migration def up create_table :refinery_retailers do |t| t.string :title t.string :contact t.string :address t.string :zipcode t.string :phone t.string :fax t.string :email t.string :website t.boolean :draft, default: true t.integer :position t.timestamps end end def down if defined?(::Refinery::UserPlugin) ::Refinery::UserPlugin.destroy_all({:name => "refinerycms-retailers"}) end if defined?(::Refinery::Page) ::Refinery::Page.delete_all({:link_url => "/retailers/retailers"}) end drop_table :refinery_retailers end end
Add default true to draft
Add default true to draft
Ruby
mit
bisscomm/refinerycms-retailers,bisscomm/refinerycms-retailers
ruby
## Code Before: class CreateRetailersRetailers < ActiveRecord::Migration def up create_table :refinery_retailers do |t| t.string :title t.string :contact t.string :address t.string :zipcode t.string :phone t.string :fax t.string :email t.string :website t.boolean :draft t.integer :position t.timestamps end end def down if defined?(::Refinery::UserPlugin) ::Refinery::UserPlugin.destroy_all({:name => "refinerycms-retailers"}) end if defined?(::Refinery::Page) ::Refinery::Page.delete_all({:link_url => "/retailers/retailers"}) end drop_table :refinery_retailers end end ## Instruction: Add default true to draft ## Code After: class CreateRetailersRetailers < ActiveRecord::Migration def up create_table :refinery_retailers do |t| t.string :title t.string :contact t.string :address t.string :zipcode t.string :phone t.string :fax t.string :email t.string :website t.boolean :draft, default: true t.integer :position t.timestamps end end def down if defined?(::Refinery::UserPlugin) ::Refinery::UserPlugin.destroy_all({:name => "refinerycms-retailers"}) end if defined?(::Refinery::Page) ::Refinery::Page.delete_all({:link_url => "/retailers/retailers"}) end drop_table :refinery_retailers end end
1516c3b52ad83d82351a1bab9aa0ccc37916d6a2
group_vars/all/files.yml
group_vars/all/files.yml
--- ## --------------------- ## Files to download ## --------------------- download_files: - url: https://raw.githubusercontent.com/99designs/aws-vault/master/completions/zsh/_aws-vault dest: "{{ ansible_user_dir }}/.oh-my-zsh/custom/plugins/aws-vault/aws-vault.plugin.zsh"
--- ## --------------------- ## Files to download ## --------------------- download_files: - url: https://raw.githubusercontent.com/99designs/aws-vault/master/contrib/completions/zsh/aws-vault.zsh dest: "{{ ansible_user_dir }}/.oh-my-zsh/custom/plugins/aws-vault/aws-vault.plugin.zsh"
Update download URL for aws vault zsh completions
Update download URL for aws vault zsh completions
YAML
mit
jradtilbrook/dotfiles,jradtilbrook/dotfiles,jradtilbrook/dotfiles
yaml
## Code Before: --- ## --------------------- ## Files to download ## --------------------- download_files: - url: https://raw.githubusercontent.com/99designs/aws-vault/master/completions/zsh/_aws-vault dest: "{{ ansible_user_dir }}/.oh-my-zsh/custom/plugins/aws-vault/aws-vault.plugin.zsh" ## Instruction: Update download URL for aws vault zsh completions ## Code After: --- ## --------------------- ## Files to download ## --------------------- download_files: - url: https://raw.githubusercontent.com/99designs/aws-vault/master/contrib/completions/zsh/aws-vault.zsh dest: "{{ ansible_user_dir }}/.oh-my-zsh/custom/plugins/aws-vault/aws-vault.plugin.zsh"
202941769bd594e31719303882df16ee6ece95c9
react/index.js
react/index.js
var deps = [ '/stdlib/tag.js', '/stdlib/observable.js' ]; function increment(x) { return String(parseInt(x, 10) + 1); } function onReady(tag, observable) { var value = observable.observe("0"); function onChange(evt) { value.set(evt.target.value); } var input = tag.tag({ name: 'input', attributes: {type: 'number', value: value}, handlers: {keyup: onChange, change: onChange} }); var inc = observable.lift(increment); var output = tag.tag({ name: 'input', attributes: {type: 'number', value: inc(value), readOnly: true} }); var div = tag.tag({name: 'div', contents: [input, output]}); yoink.define(div); } yoink.require(deps, onReady);
var deps = [ '/stdlib/tag.js', '/stdlib/observable.js' ]; function increment(x) { return String(parseInt(x, 10) + 1); } function onReady(tag, observable) { var value = observable.observe("0"); var input = tag.tag({ name: 'input', attributes: {type: 'number', value: value}, }); var inc = observable.lift(increment); var output = tag.tag({ name: 'input', attributes: {type: 'number', value: inc(value), readOnly: true} }); var div = tag.tag({name: 'div', contents: [input, output]}); yoink.define(div); } yoink.require(deps, onReady);
Add 'change' event handler if tag attribute is an observable.
Add 'change' event handler if tag attribute is an observable.
JavaScript
bsd-3-clause
garious/poochie-examples,garious/yoink-examples,garious/poochie-examples,garious/yoink-examples
javascript
## Code Before: var deps = [ '/stdlib/tag.js', '/stdlib/observable.js' ]; function increment(x) { return String(parseInt(x, 10) + 1); } function onReady(tag, observable) { var value = observable.observe("0"); function onChange(evt) { value.set(evt.target.value); } var input = tag.tag({ name: 'input', attributes: {type: 'number', value: value}, handlers: {keyup: onChange, change: onChange} }); var inc = observable.lift(increment); var output = tag.tag({ name: 'input', attributes: {type: 'number', value: inc(value), readOnly: true} }); var div = tag.tag({name: 'div', contents: [input, output]}); yoink.define(div); } yoink.require(deps, onReady); ## Instruction: Add 'change' event handler if tag attribute is an observable. ## Code After: var deps = [ '/stdlib/tag.js', '/stdlib/observable.js' ]; function increment(x) { return String(parseInt(x, 10) + 1); } function onReady(tag, observable) { var value = observable.observe("0"); var input = tag.tag({ name: 'input', attributes: {type: 'number', value: value}, }); var inc = observable.lift(increment); var output = tag.tag({ name: 'input', attributes: {type: 'number', value: inc(value), readOnly: true} }); var div = tag.tag({name: 'div', contents: [input, output]}); yoink.define(div); } yoink.require(deps, onReady);
a7171299d286804eb122e5c02bf6a7ef663f4a65
lib/modules/simple_find.rb
lib/modules/simple_find.rb
module SimpleFind module ClassMethods def find_by_name(name) self.find(:all, :params =>{:q => name}) end end def self.included(receiver) receiver.extend ClassMethods end end
module SimpleFind module ClassMethods def find_by_name(name) self.find(:all, :params =>{:q => name}) end def find(*arguments) scope = arguments.slice!(0) options = arguments.slice!(0) || {} case scope when :all then find_every(options) when :first then find(find_every(options).first.nr) when :one then find_one(options) else find_single(scope, options) end end end def self.included(receiver) receiver.extend ClassMethods end end
Patch to make find(:first) work with the OIO interface
Patch to make find(:first) work with the OIO interface
Ruby
mit
olleolleolle/oiorest,jacobat/oiorest
ruby
## Code Before: module SimpleFind module ClassMethods def find_by_name(name) self.find(:all, :params =>{:q => name}) end end def self.included(receiver) receiver.extend ClassMethods end end ## Instruction: Patch to make find(:first) work with the OIO interface ## Code After: module SimpleFind module ClassMethods def find_by_name(name) self.find(:all, :params =>{:q => name}) end def find(*arguments) scope = arguments.slice!(0) options = arguments.slice!(0) || {} case scope when :all then find_every(options) when :first then find(find_every(options).first.nr) when :one then find_one(options) else find_single(scope, options) end end end def self.included(receiver) receiver.extend ClassMethods end end
610093334d18c97b1560436d5e14aafd8efc2b34
Readme.md
Readme.md
A rubygem application that lets you deploy via rsync using --excludes and host information defined in a config file within your project. ## Example deploy-to.yml # Ignore files, relative from base (currently base is the root of the project only) ignore: [ .htaccess, .DS_Store ] # OPTIONAL: Re-define the base relative to the project root. # If this is not set, the base will be the project root. # base: lib # deploy-to sites definition remotes: # Production server production: host: example.com user: bshelton path: ~/example.com/ # Dev Server dev: host: dev.example.com user: bshelton path: ~/dev.example.com
A rubygem application that lets you deploy via rsync using --excludes and host information defined in a config file within your project. ## Example deploy-to.yml # Ignore files, relative from base (currently base is the root of the project only) ignore: [ .htaccess, .DS_Store ] # OPTIONAL: Re-define the base relative to the project root. # If this is not set, the base will be the project root. # base: lib # deploy-to sites definition remotes: # Production server production: host: example.com user: bshelton path: ~/example.com/ post_commands: ['~/bin/cleanup.sh', 'rake db:migrate'] # Dev Server dev: host: dev.example.com user: bshelton path: ~/dev.example.com
Update the readme to reflect the post_commands configuration
Update the readme to reflect the post_commands configuration
Markdown
mit
bshelton229/deploy-to
markdown
## Code Before: A rubygem application that lets you deploy via rsync using --excludes and host information defined in a config file within your project. ## Example deploy-to.yml # Ignore files, relative from base (currently base is the root of the project only) ignore: [ .htaccess, .DS_Store ] # OPTIONAL: Re-define the base relative to the project root. # If this is not set, the base will be the project root. # base: lib # deploy-to sites definition remotes: # Production server production: host: example.com user: bshelton path: ~/example.com/ # Dev Server dev: host: dev.example.com user: bshelton path: ~/dev.example.com ## Instruction: Update the readme to reflect the post_commands configuration ## Code After: A rubygem application that lets you deploy via rsync using --excludes and host information defined in a config file within your project. ## Example deploy-to.yml # Ignore files, relative from base (currently base is the root of the project only) ignore: [ .htaccess, .DS_Store ] # OPTIONAL: Re-define the base relative to the project root. # If this is not set, the base will be the project root. # base: lib # deploy-to sites definition remotes: # Production server production: host: example.com user: bshelton path: ~/example.com/ post_commands: ['~/bin/cleanup.sh', 'rake db:migrate'] # Dev Server dev: host: dev.example.com user: bshelton path: ~/dev.example.com
69948f4a4ac2372eeeea57f9df15a1f0221cefde
public/locales/ig/send.ftl
public/locales/ig/send.ftl
title = Firefox Zi ## Send version 2 strings
title = Firefox Zi fileTooBig = File a ebuka to upload. Ọ kwẹsịrọ ịkalị { $size } ## Send version 2 strings
Update Igbo (ig) localization of Firefox Send Co-authored-by: sugabelly <[email protected]>
Pontoon: Update Igbo (ig) localization of Firefox Send Co-authored-by: sugabelly <[email protected]>
FreeMarker
mpl-2.0
mozilla/send,mozilla/send,mozilla/send,mozilla/send,mozilla/send
freemarker
## Code Before: title = Firefox Zi ## Send version 2 strings ## Instruction: Pontoon: Update Igbo (ig) localization of Firefox Send Co-authored-by: sugabelly <[email protected]> ## Code After: title = Firefox Zi fileTooBig = File a ebuka to upload. Ọ kwẹsịrọ ịkalị { $size } ## Send version 2 strings
6b8b72034e4d23abf09f6dda738d9d222fa0a5dc
src/notes/programming-key-principles.md
src/notes/programming-key-principles.md
- Encapsulated - Portable - Deterministic - Explicit - Declarative - Automated - Compiled - Tested - Linted - Documented - Formatted - Reliable - Stable - Versioned - Safe - Efficient - Fast - Lightweight
- Tradeoffs - Respectful - Open-minded - Pragmatic - Encapsulated - Portable - Deterministic - Explicit - Declarative - Automated - Compiled - Tested - Linted - Documented - Formatted - Reliable - Stable - Versioned - Safe - Efficient - Fast - Lightweight
Add tradeoffs to programming principles
Add tradeoffs to programming principles
Markdown
mit
trevordmiller/shell-scripts,trevordmiller/shell-scripts
markdown
## Code Before: - Encapsulated - Portable - Deterministic - Explicit - Declarative - Automated - Compiled - Tested - Linted - Documented - Formatted - Reliable - Stable - Versioned - Safe - Efficient - Fast - Lightweight ## Instruction: Add tradeoffs to programming principles ## Code After: - Tradeoffs - Respectful - Open-minded - Pragmatic - Encapsulated - Portable - Deterministic - Explicit - Declarative - Automated - Compiled - Tested - Linted - Documented - Formatted - Reliable - Stable - Versioned - Safe - Efficient - Fast - Lightweight
2bf28746adf932641f2c13624f4329257253b4bc
src/app/components/game/game.tpl.html
src/app/components/game/game.tpl.html
<header> <span>Started at {{model.game.createdAt}}</span> <span>Round: {{model.game.round}}</span> </header> <div class="row"> <div class="col-sm-12"> <div class="play-area" ng-if="gameCtrl.isGameStarted()"> <deck type="{{::deck.deckType}}" deck-id="{{::deck.id}}" ng-repeat="deck in gameCtrl.getDecks()"></deck> </div> </div> </div> <div class="row"> <div class="col-sm-12"> <players game="model.game"></players> </div> </div> <button class="btn btn-primary new-game" ng-click="gameCtrl.create()" ng-show="!gameCtrl.isGameStarted() && playersModel.players.length >= 2"> New Game </button> <button class="btn btn-warning new-game" ng-click="gameCtrl.reset()" ng-show="gameCtrl.isGameStarted()"> RESET </button>
<header> <div class="row"> <span class="col-sm-6">Started @ {{model.game.createdAt}}</span> <span class="col-sm-4">ROUND: {{model.game.round}}</span> </div> </header> <div class="row"> <div class="col-sm-12"> <div class="play-area" ng-if="gameCtrl.isGameStarted()"> <deck type="{{::deck.deckType}}" deck-id="{{::deck.id}}" ng-repeat="deck in gameCtrl.getDecks()"></deck> </div> </div> </div> <div class="row"> <div class="col-sm-12"> <players game="model.game"></players> </div> </div> <button class="btn btn-primary new-game" ng-click="gameCtrl.create()" ng-show="!gameCtrl.isGameStarted() && playersModel.players.length >= 2"> New Game </button> <button class="btn btn-warning new-game" ng-click="gameCtrl.reset()" ng-show="gameCtrl.isGameStarted()"> RESET </button>
Update styling of content in the 'header'
Update styling of content in the 'header'
HTML
unlicense
ejwaibel/squarrels,ejwaibel/squarrels
html
## Code Before: <header> <span>Started at {{model.game.createdAt}}</span> <span>Round: {{model.game.round}}</span> </header> <div class="row"> <div class="col-sm-12"> <div class="play-area" ng-if="gameCtrl.isGameStarted()"> <deck type="{{::deck.deckType}}" deck-id="{{::deck.id}}" ng-repeat="deck in gameCtrl.getDecks()"></deck> </div> </div> </div> <div class="row"> <div class="col-sm-12"> <players game="model.game"></players> </div> </div> <button class="btn btn-primary new-game" ng-click="gameCtrl.create()" ng-show="!gameCtrl.isGameStarted() && playersModel.players.length >= 2"> New Game </button> <button class="btn btn-warning new-game" ng-click="gameCtrl.reset()" ng-show="gameCtrl.isGameStarted()"> RESET </button> ## Instruction: Update styling of content in the 'header' ## Code After: <header> <div class="row"> <span class="col-sm-6">Started @ {{model.game.createdAt}}</span> <span class="col-sm-4">ROUND: {{model.game.round}}</span> </div> </header> <div class="row"> <div class="col-sm-12"> <div class="play-area" ng-if="gameCtrl.isGameStarted()"> <deck type="{{::deck.deckType}}" deck-id="{{::deck.id}}" ng-repeat="deck in gameCtrl.getDecks()"></deck> </div> </div> </div> <div class="row"> <div class="col-sm-12"> <players game="model.game"></players> </div> </div> <button class="btn btn-primary new-game" ng-click="gameCtrl.create()" ng-show="!gameCtrl.isGameStarted() && playersModel.players.length >= 2"> New Game </button> <button class="btn btn-warning new-game" ng-click="gameCtrl.reset()" ng-show="gameCtrl.isGameStarted()"> RESET </button>
d7077c562330438fb3b21c14a0c931ae9ba0d898
app/models/vcard/swiss_match.rb
app/models/vcard/swiss_match.rb
module Vcard::SwissMatch def self.included(base) base.extend ClassMethods end def directory_lookup search = {} search[:first_name] = given_name search[:last_name] = family_name search[:street] = street_address search[:zip_code] = postal_code search[:city] = locality ::SwissMatch.directory_service.addresses(search) end def directory_match? directory_lookup.present? end module ClassMethods end end
module Vcard::SwissMatch def self.included(base) base.extend ClassMethods end def map_for_directory search = {} search[:first_name] = given_name search[:last_name] = family_name search[:street] = street_address search[:zip_code] = postal_code search[:city] = locality search end def directory_lookup(ignore_fields = []) search = map_for_directory search.reject!{|key, value| ignore_fields.include? key} ::SwissMatch.directory_service.addresses(search) end def directory_match?(ignore_fields = []) directory_lookup(ignore_fields).present? end module ClassMethods end end
Support passing an ignore_fields parameter to Vcard.directory_lookup and .directory_match?.
Support passing an ignore_fields parameter to Vcard.directory_lookup and .directory_match?.
Ruby
mit
huerlisi/has_vcards,hauledev/has_vcards,hauledev/has_vcards,huerlisi/has_vcards,huerlisi/has_vcards,hauledev/has_vcards
ruby
## Code Before: module Vcard::SwissMatch def self.included(base) base.extend ClassMethods end def directory_lookup search = {} search[:first_name] = given_name search[:last_name] = family_name search[:street] = street_address search[:zip_code] = postal_code search[:city] = locality ::SwissMatch.directory_service.addresses(search) end def directory_match? directory_lookup.present? end module ClassMethods end end ## Instruction: Support passing an ignore_fields parameter to Vcard.directory_lookup and .directory_match?. ## Code After: module Vcard::SwissMatch def self.included(base) base.extend ClassMethods end def map_for_directory search = {} search[:first_name] = given_name search[:last_name] = family_name search[:street] = street_address search[:zip_code] = postal_code search[:city] = locality search end def directory_lookup(ignore_fields = []) search = map_for_directory search.reject!{|key, value| ignore_fields.include? key} ::SwissMatch.directory_service.addresses(search) end def directory_match?(ignore_fields = []) directory_lookup(ignore_fields).present? end module ClassMethods end end
97bd1d92c0048f0e96d8db4bfe3fdd98e883a6ae
lib/premailer/rails/css_loaders/network_loader.rb
lib/premailer/rails/css_loaders/network_loader.rb
class Premailer module Rails module CSSLoaders module NetworkLoader extend self def load(url) uri = uri_for_url(url) Net::HTTP.get(uri) if uri end def uri_for_url(url) uri = URI(url) if uri.host.present? return uri if uri.scheme.present? URI("http:#{uri}") elsif asset_host_present? scheme, host = asset_host(url).split(%r{:?//}) scheme, host = host, scheme if host.nil? scheme = 'http' if scheme.blank? path = url URI(File.join("#{scheme}://#{host}", path)) end end def asset_host_present? ::Rails.respond_to?(:configuration) && ::Rails.configuration.action_controller.asset_host.present? end def asset_host(url) config = ::Rails.configuration.action_controller.asset_host config.respond_to?(:call) ? config.call(url) : config end end end end end
class Premailer module Rails module CSSLoaders module NetworkLoader extend self def load(url) uri = uri_for_url(url) Net::HTTP.get(uri, { 'Accept' => 'text/css' }) if uri end def uri_for_url(url) uri = URI(url) if uri.host.present? return uri if uri.scheme.present? URI("http:#{uri}") elsif asset_host_present? scheme, host = asset_host(url).split(%r{:?//}) scheme, host = host, scheme if host.nil? scheme = 'http' if scheme.blank? path = url URI(File.join("#{scheme}://#{host}", path)) end end def asset_host_present? ::Rails.respond_to?(:configuration) && ::Rails.configuration.action_controller.asset_host.present? end def asset_host(url) config = ::Rails.configuration.action_controller.asset_host config.respond_to?(:call) ? config.call(url) : config end end end end end
Add Accept header to requests in NetworkLoader
fix: Add Accept header to requests in NetworkLoader This allows development servers to serve the correct file type. For more information see https://github.com/ElMassimo/vite_ruby/pull/93#issuecomment-865426710
Ruby
mit
fphilipe/premailer-rails,fphilipe/premailer-rails,fphilipe/premailer-rails
ruby
## Code Before: class Premailer module Rails module CSSLoaders module NetworkLoader extend self def load(url) uri = uri_for_url(url) Net::HTTP.get(uri) if uri end def uri_for_url(url) uri = URI(url) if uri.host.present? return uri if uri.scheme.present? URI("http:#{uri}") elsif asset_host_present? scheme, host = asset_host(url).split(%r{:?//}) scheme, host = host, scheme if host.nil? scheme = 'http' if scheme.blank? path = url URI(File.join("#{scheme}://#{host}", path)) end end def asset_host_present? ::Rails.respond_to?(:configuration) && ::Rails.configuration.action_controller.asset_host.present? end def asset_host(url) config = ::Rails.configuration.action_controller.asset_host config.respond_to?(:call) ? config.call(url) : config end end end end end ## Instruction: fix: Add Accept header to requests in NetworkLoader This allows development servers to serve the correct file type. For more information see https://github.com/ElMassimo/vite_ruby/pull/93#issuecomment-865426710 ## Code After: class Premailer module Rails module CSSLoaders module NetworkLoader extend self def load(url) uri = uri_for_url(url) Net::HTTP.get(uri, { 'Accept' => 'text/css' }) if uri end def uri_for_url(url) uri = URI(url) if uri.host.present? return uri if uri.scheme.present? URI("http:#{uri}") elsif asset_host_present? scheme, host = asset_host(url).split(%r{:?//}) scheme, host = host, scheme if host.nil? scheme = 'http' if scheme.blank? path = url URI(File.join("#{scheme}://#{host}", path)) end end def asset_host_present? ::Rails.respond_to?(:configuration) && ::Rails.configuration.action_controller.asset_host.present? end def asset_host(url) config = ::Rails.configuration.action_controller.asset_host config.respond_to?(:call) ? config.call(url) : config end end end end end
df99a11ee775659482cc04409791490bb6ddb2a5
source/_partials/slideshow.blade.php
source/_partials/slideshow.blade.php
<section class="slideshow" role="landmark"> <!-- Slider main container --> <div class="swiper-container"> <!-- Additional required wrapper --> <div class="swiper-wrapper"> <!-- Slides --> @foreach ($page->images as $index => $image) <div class="swiper-slide" data-hash="{{ ++$index }}"> <div class="slide-mobile" style="background-image: url('images/content/slideshow-mobile-{{$image}}.jpg')" ></div> <div class="slide-desktop" style="background-image: url('images/content/slideshow-desktop-{{$image}}.jpg')" ></div> </div> @endforeach </div> <!-- Pagination --> <div class="swiper-pagination"></div> </div> <div class="title-card"> <img src="images/gauguin-logo.svg" alt="Gauguin, Artist as Alchemist"/> <div class="events"> <div class="event event-exhibit"> <span class="title">Exhibition</span> <span class="date">June 25 • Sept 10</span> </div> <div class="event event-"> <span class="title">Member Previews</span> <span class="date">June 22 • 24</span> </div> </div> </div> {{-- {!! $content !!} --}} </section>
<section class="slideshow" role="landmark"> <!-- Slider main container --> <div class="swiper-container"> <!-- Additional required wrapper --> <div class="swiper-wrapper"> <!-- Slides --> @foreach ($page->images as $index => $image) <div class="swiper-slide" data-hash="{{ ++$index }}"> <div class="slide-mobile" style="background-image: url('images/content/slideshow-mobile-{{$image}}.jpg')" ></div> <div class="slide-desktop" style="background-image: url('images/content/slideshow-desktop-{{$image}}.jpg')" ></div> </div> @endforeach </div> <!-- Pagination --> <div class="swiper-pagination"></div> </div> <div class="title-card"> <img src="images/gauguin-logo.svg" alt="Gauguin, Artist as Alchemist"/> <div class="events"> <div class="event event-exhibit"> <span class="title">Exhibition</span> <span class="date">June 25 • Sept 10</span> </div> </div> </div> {{-- {!! $content !!} --}} </section>
Remove preview dates from slideshow title card
Remove preview dates from slideshow title card
PHP
agpl-3.0
art-institute-of-chicago/gauguin-microsite,art-institute-of-chicago/gauguin-microsite,art-institute-of-chicago/gauguin-microsite
php
## Code Before: <section class="slideshow" role="landmark"> <!-- Slider main container --> <div class="swiper-container"> <!-- Additional required wrapper --> <div class="swiper-wrapper"> <!-- Slides --> @foreach ($page->images as $index => $image) <div class="swiper-slide" data-hash="{{ ++$index }}"> <div class="slide-mobile" style="background-image: url('images/content/slideshow-mobile-{{$image}}.jpg')" ></div> <div class="slide-desktop" style="background-image: url('images/content/slideshow-desktop-{{$image}}.jpg')" ></div> </div> @endforeach </div> <!-- Pagination --> <div class="swiper-pagination"></div> </div> <div class="title-card"> <img src="images/gauguin-logo.svg" alt="Gauguin, Artist as Alchemist"/> <div class="events"> <div class="event event-exhibit"> <span class="title">Exhibition</span> <span class="date">June 25 • Sept 10</span> </div> <div class="event event-"> <span class="title">Member Previews</span> <span class="date">June 22 • 24</span> </div> </div> </div> {{-- {!! $content !!} --}} </section> ## Instruction: Remove preview dates from slideshow title card ## Code After: <section class="slideshow" role="landmark"> <!-- Slider main container --> <div class="swiper-container"> <!-- Additional required wrapper --> <div class="swiper-wrapper"> <!-- Slides --> @foreach ($page->images as $index => $image) <div class="swiper-slide" data-hash="{{ ++$index }}"> <div class="slide-mobile" style="background-image: url('images/content/slideshow-mobile-{{$image}}.jpg')" ></div> <div class="slide-desktop" style="background-image: url('images/content/slideshow-desktop-{{$image}}.jpg')" ></div> </div> @endforeach </div> <!-- Pagination --> <div class="swiper-pagination"></div> </div> <div class="title-card"> <img src="images/gauguin-logo.svg" alt="Gauguin, Artist as Alchemist"/> <div class="events"> <div class="event event-exhibit"> <span class="title">Exhibition</span> <span class="date">June 25 • Sept 10</span> </div> </div> </div> {{-- {!! $content !!} --}} </section>
1d486d8035e918a83dce5a70c83149a06d982a9f
Instanssi/admin_calendar/models.py
Instanssi/admin_calendar/models.py
from django.db import models from django.contrib import admin from django.contrib.auth.models import User from imagekit.models import ImageSpec from imagekit.processors import resize class CalendarEvent(models.Model): user = models.ForeignKey(User, verbose_name=u'Käyttäjä') start = models.DateTimeField(u'Alku', help_text=u'Tapahtuman alkamisaika.') end = models.DateTimeField(u'Loppe', help_text=u'Tapahtuman loppumisaika.', blank=True) description = models.TextField(u'Kuvaus', help_text=u'Tapahtuman kuvaus.', blank=True) title = models.CharField(u'Otsikko', help_text=u'Lyhyt otsikko.', max_length=32) image_original = models.ImageField(u'Kuva', upload_to='calendar/images/', help_text=u"Kuva tapahtumalle.", blank=True) image_small = ImageSpec([resize.Fit(48, 48)], image_field='imagefile_original', format='PNG') EVENT_TYPES = ( (0, u'Aikaraja'), (1, u'Aikavaraus'), ) type = models.IntegerField(u'Tyyppi', help_text=u'Tapahtuman tyyppi', choices=EVENT_TYPES, default=0) try: admin.site.register(CalendarEvent) except: pass
from django.db import models from django.contrib import admin from django.contrib.auth.models import User from imagekit.models import ImageSpecField from imagekit.processors import ResizeToFill class CalendarEvent(models.Model): user = models.ForeignKey(User, verbose_name=u'Käyttäjä') start = models.DateTimeField(u'Alku', help_text=u'Tapahtuman alkamisaika.') end = models.DateTimeField(u'Loppe', help_text=u'Tapahtuman loppumisaika.', blank=True) description = models.TextField(u'Kuvaus', help_text=u'Tapahtuman kuvaus.', blank=True) title = models.CharField(u'Otsikko', help_text=u'Lyhyt otsikko.', max_length=32) image_original = models.ImageField(u'Kuva', upload_to='calendar/images/', help_text=u"Kuva tapahtumalle.", blank=True) image_small = ImageSpecField([ResizeToFill(48, 48)], image_field='imagefile_original', format='PNG') EVENT_TYPES = ( (0, u'Aikaraja'), (1, u'Aikavaraus'), ) type = models.IntegerField(u'Tyyppi', help_text=u'Tapahtuman tyyppi', choices=EVENT_TYPES, default=0) try: admin.site.register(CalendarEvent) except: pass
Fix to work on the latest django-imagekit
admin_calendar: Fix to work on the latest django-imagekit
Python
mit
Instanssi/Instanssi.org,Instanssi/Instanssi.org,Instanssi/Instanssi.org,Instanssi/Instanssi.org
python
## Code Before: from django.db import models from django.contrib import admin from django.contrib.auth.models import User from imagekit.models import ImageSpec from imagekit.processors import resize class CalendarEvent(models.Model): user = models.ForeignKey(User, verbose_name=u'Käyttäjä') start = models.DateTimeField(u'Alku', help_text=u'Tapahtuman alkamisaika.') end = models.DateTimeField(u'Loppe', help_text=u'Tapahtuman loppumisaika.', blank=True) description = models.TextField(u'Kuvaus', help_text=u'Tapahtuman kuvaus.', blank=True) title = models.CharField(u'Otsikko', help_text=u'Lyhyt otsikko.', max_length=32) image_original = models.ImageField(u'Kuva', upload_to='calendar/images/', help_text=u"Kuva tapahtumalle.", blank=True) image_small = ImageSpec([resize.Fit(48, 48)], image_field='imagefile_original', format='PNG') EVENT_TYPES = ( (0, u'Aikaraja'), (1, u'Aikavaraus'), ) type = models.IntegerField(u'Tyyppi', help_text=u'Tapahtuman tyyppi', choices=EVENT_TYPES, default=0) try: admin.site.register(CalendarEvent) except: pass ## Instruction: admin_calendar: Fix to work on the latest django-imagekit ## Code After: from django.db import models from django.contrib import admin from django.contrib.auth.models import User from imagekit.models import ImageSpecField from imagekit.processors import ResizeToFill class CalendarEvent(models.Model): user = models.ForeignKey(User, verbose_name=u'Käyttäjä') start = models.DateTimeField(u'Alku', help_text=u'Tapahtuman alkamisaika.') end = models.DateTimeField(u'Loppe', help_text=u'Tapahtuman loppumisaika.', blank=True) description = models.TextField(u'Kuvaus', help_text=u'Tapahtuman kuvaus.', blank=True) title = models.CharField(u'Otsikko', help_text=u'Lyhyt otsikko.', max_length=32) image_original = models.ImageField(u'Kuva', upload_to='calendar/images/', help_text=u"Kuva tapahtumalle.", blank=True) image_small = ImageSpecField([ResizeToFill(48, 48)], image_field='imagefile_original', format='PNG') EVENT_TYPES = ( (0, u'Aikaraja'), (1, u'Aikavaraus'), ) type = models.IntegerField(u'Tyyppi', help_text=u'Tapahtuman tyyppi', choices=EVENT_TYPES, default=0) try: admin.site.register(CalendarEvent) except: pass
ed30481e988ff29a2dfcdc23d15353bdc0ef4c04
circle.yml
circle.yml
machine: pre: - sudo rm /home/ubuntu/virtualenvs/venv-system/lib/python2.7/no-global-site-packages.txt
dependencies: pre: - sudo rm /home/ubuntu/virtualenvs/venv-system/lib/python2.7/no-global-site-packages.txt
Delete virtualenv configuration for no site packages
Delete virtualenv configuration for no site packages
YAML
agpl-3.0
okfn-brasil/gastos_abertos,LuizArmesto/gastos_abertos,okfn-brasil/gastos_abertos,nucleo-digital/gastos_abertos,LuizArmesto/gastos_abertos,andresmrm/gastos_abertos,andresmrm/gastos_abertos
yaml
## Code Before: machine: pre: - sudo rm /home/ubuntu/virtualenvs/venv-system/lib/python2.7/no-global-site-packages.txt ## Instruction: Delete virtualenv configuration for no site packages ## Code After: dependencies: pre: - sudo rm /home/ubuntu/virtualenvs/venv-system/lib/python2.7/no-global-site-packages.txt
6ce14f21cec2c37939f68aaf40d5227c80636e53
app_bikes/forms.py
app_bikes/forms.py
from dal import autocomplete from django import forms class BikeModelForm(forms.ModelForm): def __init__(self, *args, **kw): super(BikeModelForm, self).__init__(*args, **kw) if self.instance is not None: # Saved instance is loaded, setup choices to display the selected value self.fields['id_station'].widget.choices = ((self.instance.id_station, self.instance.station),) def validate_unique(self): super(BikeModelForm, self).validate_unique() if self.errors and 'id_station' in self.data: # A station was chosen, reinit choices with it self.fields['id_station'].widget.choices = ((self.cleaned_data['id_station'], self.data['station']),) class Meta: widgets = { 'id_station': autocomplete.ListSelect2(url='station-autocomplete', forward=('provider',), attrs={'data-allow-clear': 'false'}) } class Media: js = ('js/admin_form.js',)
from dal import autocomplete from django import forms class BikeModelForm(forms.ModelForm): def __init__(self, *args, **kw): super(BikeModelForm, self).__init__(*args, **kw) if self.instance is not None: # Saved instance is loaded, setup choices to display the selected value self.fields['id_station'].widget.choices = ((self.instance.id_station, self.instance.station),) def validate_unique(self): """If the form had an error and a station was chosen, we need to setup the widget choices to the previously selected value for the autocomplete to display it properly""" super(BikeModelForm, self).validate_unique() if self.errors and 'id_station' in self.data: self.fields['id_station'].widget.choices = ((self.cleaned_data['id_station'], self.data['station']),) class Meta: widgets = { 'id_station': autocomplete.ListSelect2(url='station-autocomplete', forward=('provider',), attrs={'data-allow-clear': 'false'}) } class Media: js = ('js/admin_form.js',)
Add docstring to explain the code
Add docstring to explain the code
Python
agpl-3.0
laboiteproject/laboite-backend,laboiteproject/laboite-backend,bgaultier/laboitepro,bgaultier/laboitepro,bgaultier/laboitepro,laboiteproject/laboite-backend
python
## Code Before: from dal import autocomplete from django import forms class BikeModelForm(forms.ModelForm): def __init__(self, *args, **kw): super(BikeModelForm, self).__init__(*args, **kw) if self.instance is not None: # Saved instance is loaded, setup choices to display the selected value self.fields['id_station'].widget.choices = ((self.instance.id_station, self.instance.station),) def validate_unique(self): super(BikeModelForm, self).validate_unique() if self.errors and 'id_station' in self.data: # A station was chosen, reinit choices with it self.fields['id_station'].widget.choices = ((self.cleaned_data['id_station'], self.data['station']),) class Meta: widgets = { 'id_station': autocomplete.ListSelect2(url='station-autocomplete', forward=('provider',), attrs={'data-allow-clear': 'false'}) } class Media: js = ('js/admin_form.js',) ## Instruction: Add docstring to explain the code ## Code After: from dal import autocomplete from django import forms class BikeModelForm(forms.ModelForm): def __init__(self, *args, **kw): super(BikeModelForm, self).__init__(*args, **kw) if self.instance is not None: # Saved instance is loaded, setup choices to display the selected value self.fields['id_station'].widget.choices = ((self.instance.id_station, self.instance.station),) def validate_unique(self): """If the form had an error and a station was chosen, we need to setup the widget choices to the previously selected value for the autocomplete to display it properly""" super(BikeModelForm, self).validate_unique() if self.errors and 'id_station' in self.data: self.fields['id_station'].widget.choices = ((self.cleaned_data['id_station'], self.data['station']),) class Meta: widgets = { 'id_station': autocomplete.ListSelect2(url='station-autocomplete', forward=('provider',), attrs={'data-allow-clear': 'false'}) } class Media: js = ('js/admin_form.js',)
e016b68acd1b0176bb67e0803e12698e0ab4e63d
src/util/verticalRhythm.js
src/util/verticalRhythm.js
import ms from 'modularscale' // Calculate box model values that conforms to the established Vertical Rhythm export function boxModelRuleVerticalRhythm ( size, { baseFontSize, lineHeightRatio } ) { if (!size) { return null } const baseline = Math.floor(lineHeightRatio * baseFontSize) const retval = baseline * size // Compensate for rounding errors that make the return value not divisible const offset = retval % baseline return `${retval - offset}px` } // Calculate typographic values that conforms to the established Vertical Rhythm export function typographyVerticalRhythm ( size, { baseFontSize, lineHeightRatio, scaleRatio } ) { const fontSize = ms(size, scaleRatio) const multiplier = Math.ceil(fontSize / lineHeightRatio) return { fontSize: `${fontSize}rem`, lineHeight: boxModelRuleVerticalRhythm(multiplier, { baseFontSize, lineHeightRatio }) } }
import ms from 'modularscale' // Calculate box model values that conforms to the established Vertical Rhythm export function boxModelRuleVerticalRhythm ( size, { baseFontSize, lineHeightRatio } ) { if (size === undefined || size == null) { return size } const baseline = Math.floor(lineHeightRatio * baseFontSize) const retval = baseline * size // Compensate for rounding errors that make the return value not divisible const offset = retval % baseline return `${retval - offset}px` } // Calculate typographic values that conforms to the established Vertical Rhythm export function typographyVerticalRhythm ( size, { baseFontSize, lineHeightRatio, scaleRatio } ) { const fontSize = ms(size, scaleRatio) const multiplier = Math.ceil(fontSize / lineHeightRatio) return { fontSize: `${fontSize}rem`, lineHeight: boxModelRuleVerticalRhythm(multiplier, { baseFontSize, lineHeightRatio }) } }
Fix bug that prevented vertical rhythm scaling for 0 values
Fix bug that prevented vertical rhythm scaling for 0 values
JavaScript
mit
dlindahl/stemcell,dlindahl/stemcell
javascript
## Code Before: import ms from 'modularscale' // Calculate box model values that conforms to the established Vertical Rhythm export function boxModelRuleVerticalRhythm ( size, { baseFontSize, lineHeightRatio } ) { if (!size) { return null } const baseline = Math.floor(lineHeightRatio * baseFontSize) const retval = baseline * size // Compensate for rounding errors that make the return value not divisible const offset = retval % baseline return `${retval - offset}px` } // Calculate typographic values that conforms to the established Vertical Rhythm export function typographyVerticalRhythm ( size, { baseFontSize, lineHeightRatio, scaleRatio } ) { const fontSize = ms(size, scaleRatio) const multiplier = Math.ceil(fontSize / lineHeightRatio) return { fontSize: `${fontSize}rem`, lineHeight: boxModelRuleVerticalRhythm(multiplier, { baseFontSize, lineHeightRatio }) } } ## Instruction: Fix bug that prevented vertical rhythm scaling for 0 values ## Code After: import ms from 'modularscale' // Calculate box model values that conforms to the established Vertical Rhythm export function boxModelRuleVerticalRhythm ( size, { baseFontSize, lineHeightRatio } ) { if (size === undefined || size == null) { return size } const baseline = Math.floor(lineHeightRatio * baseFontSize) const retval = baseline * size // Compensate for rounding errors that make the return value not divisible const offset = retval % baseline return `${retval - offset}px` } // Calculate typographic values that conforms to the established Vertical Rhythm export function typographyVerticalRhythm ( size, { baseFontSize, lineHeightRatio, scaleRatio } ) { const fontSize = ms(size, scaleRatio) const multiplier = Math.ceil(fontSize / lineHeightRatio) return { fontSize: `${fontSize}rem`, lineHeight: boxModelRuleVerticalRhythm(multiplier, { baseFontSize, lineHeightRatio }) } }
65aad32c8ecbecf7228e16e0a3025db6aa4a57a0
_data/navigation.yml
_data/navigation.yml
- title: Home url: "/" side: left - title: Blog url: "/blog/" side: left dropdown: - title: Blog url: "/blog/" - title: "Arquivos do Blog" url: "/blog/arquivo/" - title: "Galeria" url: "/galeria/" side: left dropdown: - title: Eventos e Palestras url: "/galeria/eventos/" - title: "Seja uma autora" url: "/parceria-inspirada/" side: left - title: "Quem Somos" url: "/sobre/" side: left dropdown: - title: Sobre url: "/sobre/" - title: Equipe url: "/equipe/" - title: Colaboradoras url: "/colaboradoras/" - title: "Contato" url: "/contato/" side: left - title: "Pesquisar" url: "/search/" side: right
- title: Home url: "/" side: left - title: Blog url: "/blog/" side: left dropdown: - title: Blog url: "/blog/" - title: "Arquivos do Blog" url: "/blog/arquivo/" - title: "Galeria" url: "/galeria/" side: left dropdown: - title: Eventos e Palestras url: "/galeria/eventos/" - title: "Seja uma autora" url: "/parceria-inspirada/" side: left - title: "Quem Somos" url: "/sobre/" side: left dropdown: - title: Sobre url: "/sobre/" - title: Equipe url: "/equipe/" - title: Colaboradoras url: "/colaboradoras/" - title: "Contato" url: "/contato/" side: left - title: "Pesquisar" url: "/search/" side: right - title: "Doar" url: "https://pagseguro.uol.com.br/checkout/nc/nl/donation/sender-identification.jhtml?t=4d1c06e05efea28695d0359c78e99679#rmcl" side: right
Revert "retirando link doar para corrigir bug"
Revert "retirando link doar para corrigir bug" This reverts commit 494d6fad7d20201248e6cadfac64dc0560d8333f.
YAML
mit
inspiradanacomputacao/inspiradanacomputacao.github.io,teste-blog-inspirada/teste-blog-inspirada.github.io,teste-blog-inspirada/teste-blog-inspirada.github.io,teste-blog-inspirada/teste-blog-inspirada.github.io,inspiradanacomputacao/inspiradanacomputacao.github.io,inspiradanacomputacao/inspiradanacomputacao.github.io,teste-blog-inspirada/teste-blog-inspirada.github.io,inspiradanacomputacao/inspiradanacomputacao.github.io
yaml
## Code Before: - title: Home url: "/" side: left - title: Blog url: "/blog/" side: left dropdown: - title: Blog url: "/blog/" - title: "Arquivos do Blog" url: "/blog/arquivo/" - title: "Galeria" url: "/galeria/" side: left dropdown: - title: Eventos e Palestras url: "/galeria/eventos/" - title: "Seja uma autora" url: "/parceria-inspirada/" side: left - title: "Quem Somos" url: "/sobre/" side: left dropdown: - title: Sobre url: "/sobre/" - title: Equipe url: "/equipe/" - title: Colaboradoras url: "/colaboradoras/" - title: "Contato" url: "/contato/" side: left - title: "Pesquisar" url: "/search/" side: right ## Instruction: Revert "retirando link doar para corrigir bug" This reverts commit 494d6fad7d20201248e6cadfac64dc0560d8333f. ## Code After: - title: Home url: "/" side: left - title: Blog url: "/blog/" side: left dropdown: - title: Blog url: "/blog/" - title: "Arquivos do Blog" url: "/blog/arquivo/" - title: "Galeria" url: "/galeria/" side: left dropdown: - title: Eventos e Palestras url: "/galeria/eventos/" - title: "Seja uma autora" url: "/parceria-inspirada/" side: left - title: "Quem Somos" url: "/sobre/" side: left dropdown: - title: Sobre url: "/sobre/" - title: Equipe url: "/equipe/" - title: Colaboradoras url: "/colaboradoras/" - title: "Contato" url: "/contato/" side: left - title: "Pesquisar" url: "/search/" side: right - title: "Doar" url: "https://pagseguro.uol.com.br/checkout/nc/nl/donation/sender-identification.jhtml?t=4d1c06e05efea28695d0359c78e99679#rmcl" side: right
c6bc3b638ec527e4ff301fc56adeb918951e47f1
autogen.sh
autogen.sh
set -x (git rev-parse HEAD ; git describe) 2> /dev/null > src/githash aclocal -I config #autoheader libtoolize --automake touch AUTHORS ChangeLog automake --add-missing --copy autoconf
set -x (git rev-parse HEAD ; git describe) 2> /dev/null > src/githash if [ ! -d "config" ] ; then mkdir config fi aclocal -I config #autoheader libtoolize --automake touch AUTHORS touch ChangeLog automake --add-missing --copy autoconf
Make config directory as needed
Make config directory as needed Signed-off-by: Owen Synge <[email protected]>
Shell
lgpl-2.1
osynge/whenenv-rust,osynge/whenenv-rust
shell
## Code Before: set -x (git rev-parse HEAD ; git describe) 2> /dev/null > src/githash aclocal -I config #autoheader libtoolize --automake touch AUTHORS ChangeLog automake --add-missing --copy autoconf ## Instruction: Make config directory as needed Signed-off-by: Owen Synge <[email protected]> ## Code After: set -x (git rev-parse HEAD ; git describe) 2> /dev/null > src/githash if [ ! -d "config" ] ; then mkdir config fi aclocal -I config #autoheader libtoolize --automake touch AUTHORS touch ChangeLog automake --add-missing --copy autoconf
74e4e11d24300fd302fa2fa7729510c759496b69
lib/vidibus/sysinfo/result.rb
lib/vidibus/sysinfo/result.rb
module Vidibus module Sysinfo class Result include Helper def initialize(options) @@attrs.each do |attr| instance_variable_set("@#{attr}", options[attr]) end end class << self def attrs(*args) self.send(:attr, *args) @@attrs = args end end end end end
module Vidibus module Sysinfo class Result include Helper def initialize(options) attrs.each do |attr| instance_variable_set("@#{attr}", options[attr]) end end private def attrs self.class.instance_variable_get('@attrs') end class << self def attrs(*args) self.send(:attr, *args) @attrs = args end end end end end
Fix access of class level attrs
Fix access of class level attrs
Ruby
mit
vidibus/vidibus-sysinfo
ruby
## Code Before: module Vidibus module Sysinfo class Result include Helper def initialize(options) @@attrs.each do |attr| instance_variable_set("@#{attr}", options[attr]) end end class << self def attrs(*args) self.send(:attr, *args) @@attrs = args end end end end end ## Instruction: Fix access of class level attrs ## Code After: module Vidibus module Sysinfo class Result include Helper def initialize(options) attrs.each do |attr| instance_variable_set("@#{attr}", options[attr]) end end private def attrs self.class.instance_variable_get('@attrs') end class << self def attrs(*args) self.send(:attr, *args) @attrs = args end end end end end
d58d68a2990c6effd98093957bb7520814508fcd
web/static/js/battle_snake/board_viewer.js
web/static/js/battle_snake/board_viewer.js
import Mousetrap from "mousetrap"; import $ from "jquery"; import socket from "../socket" import "../empties/modal"; const logError = resp => { console.error("Unable to join", resp) }; const init = (gameId) => { if(typeof gameId === "undefined") { return; } const boardViewerChannel = socket.channel(`board_viewer:${gameId}`, {contentType: "html"}); const gameAdminChannel = socket.channel(`game_admin:${gameId}`); boardViewerChannel.on("tick", ({content}) => { $("#board-viewer").html() }); boardViewerChannel. join(). receive("error", logError); gameAdminChannel. join(). receive("error", logError); const cmd = (request) => { console.log(request); gameAdminChannel. push(request). receive("error", e => console.error(`push "${request}" failed`, e)); }; Mousetrap.bind(["q"], () => cmd("stop")); Mousetrap.bind(["h", "left"], () => cmd("prev")); Mousetrap.bind(["j", "up"], () => cmd("resume")); Mousetrap.bind(["k", "down"], () => cmd("pause")); Mousetrap.bind(["l", "right"], () => cmd("next")); Mousetrap.bind("R", () => cmd("replay")); }; export default { init };
import Mousetrap from "mousetrap"; import socket from "../socket" import "../empties/modal"; const logError = resp => { console.error("Unable to join", resp) }; const init = (gameId) => { if(typeof gameId === "undefined") { return; } const boardViewerChannel = socket.channel(`board_viewer:${gameId}`, {contentType: "html"}); const gameAdminChannel = socket.channel(`game_admin:${gameId}`); boardViewerChannel.on("tick", ({content}) => { document.getElementById("board-viewer").innerHTML = content; }); boardViewerChannel. join(). receive("error", logError); gameAdminChannel. join(). receive("error", logError); const cmd = (request) => { console.log(request); gameAdminChannel. push(request). receive("error", e => console.error(`push "${request}" failed`, e)); }; Mousetrap.bind(["q"], () => cmd("stop")); Mousetrap.bind(["h", "left"], () => cmd("prev")); Mousetrap.bind(["j", "up"], () => cmd("resume")); Mousetrap.bind(["k", "down"], () => cmd("pause")); Mousetrap.bind(["l", "right"], () => cmd("next")); Mousetrap.bind("R", () => cmd("replay")); }; export default { init };
Optimize dom replacement for board viewer
Optimize dom replacement for board viewer This one line cuts down the "loading" slice from the chrome timeline from 25% to 3%. jQuery.html performs a very expensive html validation before inserting to into the dom. Because we *hope* that we're sending valid html before hand we don't need to do this. This leaves page redraw and paint as the next largest bottleneck, which cannot be overcome without using something other than svg.
JavaScript
agpl-3.0
Dkendal/battle_snake,Dkendal/battle_snake,Dkendal/battle_snake,Dkendal/battle_snake,Dkendal/battle_snake
javascript
## Code Before: import Mousetrap from "mousetrap"; import $ from "jquery"; import socket from "../socket" import "../empties/modal"; const logError = resp => { console.error("Unable to join", resp) }; const init = (gameId) => { if(typeof gameId === "undefined") { return; } const boardViewerChannel = socket.channel(`board_viewer:${gameId}`, {contentType: "html"}); const gameAdminChannel = socket.channel(`game_admin:${gameId}`); boardViewerChannel.on("tick", ({content}) => { $("#board-viewer").html() }); boardViewerChannel. join(). receive("error", logError); gameAdminChannel. join(). receive("error", logError); const cmd = (request) => { console.log(request); gameAdminChannel. push(request). receive("error", e => console.error(`push "${request}" failed`, e)); }; Mousetrap.bind(["q"], () => cmd("stop")); Mousetrap.bind(["h", "left"], () => cmd("prev")); Mousetrap.bind(["j", "up"], () => cmd("resume")); Mousetrap.bind(["k", "down"], () => cmd("pause")); Mousetrap.bind(["l", "right"], () => cmd("next")); Mousetrap.bind("R", () => cmd("replay")); }; export default { init }; ## Instruction: Optimize dom replacement for board viewer This one line cuts down the "loading" slice from the chrome timeline from 25% to 3%. jQuery.html performs a very expensive html validation before inserting to into the dom. Because we *hope* that we're sending valid html before hand we don't need to do this. This leaves page redraw and paint as the next largest bottleneck, which cannot be overcome without using something other than svg. ## Code After: import Mousetrap from "mousetrap"; import socket from "../socket" import "../empties/modal"; const logError = resp => { console.error("Unable to join", resp) }; const init = (gameId) => { if(typeof gameId === "undefined") { return; } const boardViewerChannel = socket.channel(`board_viewer:${gameId}`, {contentType: "html"}); const gameAdminChannel = socket.channel(`game_admin:${gameId}`); boardViewerChannel.on("tick", ({content}) => { document.getElementById("board-viewer").innerHTML = content; }); boardViewerChannel. join(). receive("error", logError); gameAdminChannel. join(). receive("error", logError); const cmd = (request) => { console.log(request); gameAdminChannel. push(request). receive("error", e => console.error(`push "${request}" failed`, e)); }; Mousetrap.bind(["q"], () => cmd("stop")); Mousetrap.bind(["h", "left"], () => cmd("prev")); Mousetrap.bind(["j", "up"], () => cmd("resume")); Mousetrap.bind(["k", "down"], () => cmd("pause")); Mousetrap.bind(["l", "right"], () => cmd("next")); Mousetrap.bind("R", () => cmd("replay")); }; export default { init };
13e2740bd9f644da0db59af55a3f45d53d5540fa
setup.cfg
setup.cfg
[metadata] name = glue-vispy-viewers url = https://github.com/glue-viz/glue-3d-viewer author = Thomas Robitaille, Penny Qian, and Maxwell Tsai author_email = [email protected] description = Vispy-based viewers for Glue long_description = file: README.rst [options] zip_safe = True packages = find: setup_requires = setuptools_scm install_requires = numpy pyopengl glue-core>=0.15 qtpy scipy astropy>=1.1 pillow [options.entry_points] glue.plugins = vispy_volume = glue_vispy_viewers.volume:setup vispy_scatter = glue_vispy_viewers.scatter:setup #vispy_isosurface=glue_vispy_viewers.isosurface:setup [options.extras_require] test = pytest>=3.5,<3.7 pytest-cov pytest-qt pytest-faulthandler<1.6 objgraph mock qt = PyQt5;python_version>="3" [options.package_data] * = *.ui, *.png, *.glu, *.vert, *.frag, *.js, *.npy
[metadata] name = glue-vispy-viewers url = https://github.com/glue-viz/glue-3d-viewer author = Thomas Robitaille, Penny Qian, and Maxwell Tsai author_email = [email protected] description = Vispy-based viewers for Glue long_description = file: README.rst [options] zip_safe = True packages = find: setup_requires = setuptools_scm install_requires = numpy pyopengl glue-core>=0.15 qtpy scipy astropy>=1.1 pillow matplotlib [options.entry_points] glue.plugins = vispy_volume = glue_vispy_viewers.volume:setup vispy_scatter = glue_vispy_viewers.scatter:setup #vispy_isosurface=glue_vispy_viewers.isosurface:setup [options.extras_require] test = pytest>=3.5,<3.7 pytest-cov pytest-qt pytest-faulthandler<1.6 objgraph mock qt = PyQt5;python_version>="3" [options.package_data] * = *.ui, *.png, *.glu, *.vert, *.frag, *.js, *.npy
Include matplotlib in install_requires since it's used in glue_vispy_viewers.volume
Include matplotlib in install_requires since it's used in glue_vispy_viewers.volume
INI
bsd-2-clause
PennyQ/astro-vispy,glue-viz/glue-3d-viewer,glue-viz/glue-vispy-viewers
ini
## Code Before: [metadata] name = glue-vispy-viewers url = https://github.com/glue-viz/glue-3d-viewer author = Thomas Robitaille, Penny Qian, and Maxwell Tsai author_email = [email protected] description = Vispy-based viewers for Glue long_description = file: README.rst [options] zip_safe = True packages = find: setup_requires = setuptools_scm install_requires = numpy pyopengl glue-core>=0.15 qtpy scipy astropy>=1.1 pillow [options.entry_points] glue.plugins = vispy_volume = glue_vispy_viewers.volume:setup vispy_scatter = glue_vispy_viewers.scatter:setup #vispy_isosurface=glue_vispy_viewers.isosurface:setup [options.extras_require] test = pytest>=3.5,<3.7 pytest-cov pytest-qt pytest-faulthandler<1.6 objgraph mock qt = PyQt5;python_version>="3" [options.package_data] * = *.ui, *.png, *.glu, *.vert, *.frag, *.js, *.npy ## Instruction: Include matplotlib in install_requires since it's used in glue_vispy_viewers.volume ## Code After: [metadata] name = glue-vispy-viewers url = https://github.com/glue-viz/glue-3d-viewer author = Thomas Robitaille, Penny Qian, and Maxwell Tsai author_email = [email protected] description = Vispy-based viewers for Glue long_description = file: README.rst [options] zip_safe = True packages = find: setup_requires = setuptools_scm install_requires = numpy pyopengl glue-core>=0.15 qtpy scipy astropy>=1.1 pillow matplotlib [options.entry_points] glue.plugins = vispy_volume = glue_vispy_viewers.volume:setup vispy_scatter = glue_vispy_viewers.scatter:setup #vispy_isosurface=glue_vispy_viewers.isosurface:setup [options.extras_require] test = pytest>=3.5,<3.7 pytest-cov pytest-qt pytest-faulthandler<1.6 objgraph mock qt = PyQt5;python_version>="3" [options.package_data] * = *.ui, *.png, *.glu, *.vert, *.frag, *.js, *.npy
14c9b9d09ea5e16060bb00116cae54c550a01f67
app/views/references/update.js.erb
app/views/references/update.js.erb
$('.message-container').html(''); $('input#reference-parent-typeahead').val('<%= @reference.parent.try('citation').try('html_safe') %>'); $('a#tab-heading').html('<%= @reference.citation %>'); $('#search-result-details-info-message-container').html('<%= @message %>'); $('select#reference_ref_type_id').focus(); <% unless @message.match(/^No change/) %> $('a#Reference-<%= @reference.id %>').html('<%= escape_javascript(render partial: 'reference_link_text', locals: {reference: @reference}) %>'); $('input#reference-author-typeahead').val('<%= @reference.author.try('name').try('html_safe') %>'); <% end %>
$('.message-container').html(''); $('input#reference-parent-typeahead').val('<%= @reference.parent.try('citation').try('html_safe') %>'); $('a#tab-heading').html('<%= @reference.citation %>'); $('#search-result-details-info-message-container').html('<%= @message %>'); $('select#reference_ref_type_id').focus(); <% unless @message.match(/^No change/) %> $('a#Reference-<%= @reference.id %>').html('<%= escape_javascript(render partial: 'reference_link_text', locals: {reference: @reference}) %>'); $('input#reference-author-typeahead').val('<%= escape_javascript(@reference.author.try('name').try('html_safe')) %>'); <% end %>
Update message now shows even for refs with apostrophe in citation - using escape_javascript.
Update message now shows even for refs with apostrophe in citation - using escape_javascript.
HTML+ERB
apache-2.0
bio-org-au/nsl-editor,bio-org-au/nsl-editor,bio-org-au/nsl-editor,bio-org-au/nsl-editor
html+erb
## Code Before: $('.message-container').html(''); $('input#reference-parent-typeahead').val('<%= @reference.parent.try('citation').try('html_safe') %>'); $('a#tab-heading').html('<%= @reference.citation %>'); $('#search-result-details-info-message-container').html('<%= @message %>'); $('select#reference_ref_type_id').focus(); <% unless @message.match(/^No change/) %> $('a#Reference-<%= @reference.id %>').html('<%= escape_javascript(render partial: 'reference_link_text', locals: {reference: @reference}) %>'); $('input#reference-author-typeahead').val('<%= @reference.author.try('name').try('html_safe') %>'); <% end %> ## Instruction: Update message now shows even for refs with apostrophe in citation - using escape_javascript. ## Code After: $('.message-container').html(''); $('input#reference-parent-typeahead').val('<%= @reference.parent.try('citation').try('html_safe') %>'); $('a#tab-heading').html('<%= @reference.citation %>'); $('#search-result-details-info-message-container').html('<%= @message %>'); $('select#reference_ref_type_id').focus(); <% unless @message.match(/^No change/) %> $('a#Reference-<%= @reference.id %>').html('<%= escape_javascript(render partial: 'reference_link_text', locals: {reference: @reference}) %>'); $('input#reference-author-typeahead').val('<%= escape_javascript(@reference.author.try('name').try('html_safe')) %>'); <% end %>
fa300c48b25caa51d38bd8f78d28b9ad9da82d37
README.md
README.md
Like `chmod -R`. Takes the same arguments as `fs.chmod()`
Has the same effect as the command line command: `chmod -R`. ## Install ``` npm i --save chmodr ``` ## Usage Takes the same arguments as [`fs.chmod()`](https://nodejs.org/api/fs.html#fs_fs_chmod_path_mode_callback) chmodr(path, mode, callback) * path `<string>` | `<Buffer>` | `<URL>` * mode `<integer>` * callback `<Function>` * err `<Error>` ## Example ```javascript var chmodr = require('chmodr'); chmodr('/var/www/my/test/folder', 0o777, (err) => { if (err) { console.log('Failed to execute chmod', err); } else { console.log('Success'); } }); ```
Add usage and examples in readme
Add usage and examples in readme
Markdown
isc
isaacs/chmodr
markdown
## Code Before: Like `chmod -R`. Takes the same arguments as `fs.chmod()` ## Instruction: Add usage and examples in readme ## Code After: Has the same effect as the command line command: `chmod -R`. ## Install ``` npm i --save chmodr ``` ## Usage Takes the same arguments as [`fs.chmod()`](https://nodejs.org/api/fs.html#fs_fs_chmod_path_mode_callback) chmodr(path, mode, callback) * path `<string>` | `<Buffer>` | `<URL>` * mode `<integer>` * callback `<Function>` * err `<Error>` ## Example ```javascript var chmodr = require('chmodr'); chmodr('/var/www/my/test/folder', 0o777, (err) => { if (err) { console.log('Failed to execute chmod', err); } else { console.log('Success'); } }); ```
1532259fcae8712777e1cedefc91224ee60a6aaa
src/test/fuzz/parse_hd_keypath.cpp
src/test/fuzz/parse_hd_keypath.cpp
// Copyright (c) 2009-2019 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include <test/fuzz/fuzz.h> #include <util/bip32.h> void test_one_input(const std::vector<uint8_t>& buffer) { const std::string keypath_str(buffer.begin(), buffer.end()); std::vector<uint32_t> keypath; (void)ParseHDKeypath(keypath_str, keypath); }
// Copyright (c) 2009-2019 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include <test/fuzz/FuzzedDataProvider.h> #include <test/fuzz/fuzz.h> #include <test/fuzz/util.h> #include <util/bip32.h> #include <cstdint> #include <vector> void test_one_input(const std::vector<uint8_t>& buffer) { const std::string keypath_str(buffer.begin(), buffer.end()); std::vector<uint32_t> keypath; (void)ParseHDKeypath(keypath_str, keypath); FuzzedDataProvider fuzzed_data_provider(buffer.data(), buffer.size()); const std::vector<uint32_t> random_keypath = ConsumeRandomLengthIntegralVector<uint32_t>(fuzzed_data_provider); (void)FormatHDKeypath(random_keypath); (void)WriteHDKeypath(random_keypath); }
Add fuzzing coverage for FormatHDKeypath(...) and WriteHDKeypath(...)
tests: Add fuzzing coverage for FormatHDKeypath(...) and WriteHDKeypath(...)
C++
mit
achow101/bitcoin,n1bor/bitcoin,jlopp/statoshi,instagibbs/bitcoin,n1bor/bitcoin,AkioNak/bitcoin,AkioNak/bitcoin,anditto/bitcoin,jambolo/bitcoin,tecnovert/particl-core,AkioNak/bitcoin,MeshCollider/bitcoin,jamesob/bitcoin,Sjors/bitcoin,sstone/bitcoin,practicalswift/bitcoin,rnicoll/bitcoin,anditto/bitcoin,apoelstra/bitcoin,lateminer/bitcoin,jnewbery/bitcoin,jnewbery/bitcoin,kallewoof/bitcoin,bitcoin/bitcoin,sstone/bitcoin,ajtowns/bitcoin,JeremyRubin/bitcoin,instagibbs/bitcoin,alecalve/bitcoin,MeshCollider/bitcoin,GroestlCoin/bitcoin,namecoin/namecore,namecoin/namecore,rnicoll/dogecoin,EthanHeilman/bitcoin,sstone/bitcoin,GroestlCoin/GroestlCoin,JeremyRubin/bitcoin,tecnovert/particl-core,n1bor/bitcoin,jambolo/bitcoin,domob1812/namecore,n1bor/bitcoin,bitcoinsSG/bitcoin,fanquake/bitcoin,alecalve/bitcoin,lateminer/bitcoin,JeremyRubin/bitcoin,jamesob/bitcoin,midnightmagic/bitcoin,domob1812/namecore,jambolo/bitcoin,jnewbery/bitcoin,AkioNak/bitcoin,pstratem/bitcoin,apoelstra/bitcoin,achow101/bitcoin,kallewoof/bitcoin,mruddy/bitcoin,sstone/bitcoin,rnicoll/dogecoin,EthanHeilman/bitcoin,pstratem/bitcoin,fujicoin/fujicoin,jlopp/statoshi,Xekyo/bitcoin,rnicoll/dogecoin,MeshCollider/bitcoin,litecoin-project/litecoin,midnightmagic/bitcoin,particl/particl-core,bitcoinsSG/bitcoin,MeshCollider/bitcoin,domob1812/bitcoin,MarcoFalke/bitcoin,bitcoin/bitcoin,midnightmagic/bitcoin,fanquake/bitcoin,MarcoFalke/bitcoin,jambolo/bitcoin,jlopp/statoshi,ElementsProject/elements,jonasschnelli/bitcoin,midnightmagic/bitcoin,MeshCollider/bitcoin,jnewbery/bitcoin,domob1812/namecore,namecoin/namecoin-core,JeremyRubin/bitcoin,jamesob/bitcoin,jonasschnelli/bitcoin,MarcoFalke/bitcoin,ElementsProject/elements,Xekyo/bitcoin,mm-s/bitcoin,kallewoof/bitcoin,EthanHeilman/bitcoin,instagibbs/bitcoin,qtumproject/qtum,pataquets/namecoin-core,anditto/bitcoin,lateminer/bitcoin,midnightmagic/bitcoin,particl/particl-core,sipsorcery/bitcoin,lateminer/bitcoin,yenliangl/bitcoin,Xekyo/bitcoin,litecoin-project/litecoin,apoelstra/bitcoin,Sjors/bitcoin,JeremyRubin/bitcoin,domob1812/bitcoin,namecoin/namecore,domob1812/bitcoin,GroestlCoin/GroestlCoin,GroestlCoin/GroestlCoin,domob1812/namecore,rnicoll/bitcoin,pstratem/bitcoin,fanquake/bitcoin,namecoin/namecoin-core,AkioNak/bitcoin,mruddy/bitcoin,namecoin/namecoin-core,jonasschnelli/bitcoin,practicalswift/bitcoin,fanquake/bitcoin,qtumproject/qtum,MarcoFalke/bitcoin,fujicoin/fujicoin,fujicoin/fujicoin,domob1812/namecore,EthanHeilman/bitcoin,yenliangl/bitcoin,jlopp/statoshi,AkioNak/bitcoin,practicalswift/bitcoin,bitcoin/bitcoin,particl/particl-core,bitcoin/bitcoin,yenliangl/bitcoin,Sjors/bitcoin,bitcoinknots/bitcoin,cdecker/bitcoin,practicalswift/bitcoin,andreaskern/bitcoin,dscotese/bitcoin,namecoin/namecore,ElementsProject/elements,fanquake/bitcoin,instagibbs/bitcoin,namecoin/namecoin-core,practicalswift/bitcoin,anditto/bitcoin,GroestlCoin/GroestlCoin,namecoin/namecore,qtumproject/qtum,GroestlCoin/GroestlCoin,prusnak/bitcoin,prusnak/bitcoin,domob1812/namecore,litecoin-project/litecoin,sstone/bitcoin,andreaskern/bitcoin,rnicoll/dogecoin,GroestlCoin/bitcoin,qtumproject/qtum,domob1812/bitcoin,ajtowns/bitcoin,anditto/bitcoin,andreaskern/bitcoin,qtumproject/qtum,domob1812/bitcoin,namecoin/namecoin-core,rnicoll/bitcoin,jamesob/bitcoin,sipsorcery/bitcoin,achow101/bitcoin,GroestlCoin/bitcoin,ElementsProject/elements,pstratem/bitcoin,prusnak/bitcoin,namecoin/namecoin-core,EthanHeilman/bitcoin,GroestlCoin/bitcoin,fujicoin/fujicoin,ajtowns/bitcoin,jamesob/bitcoin,bitcoin/bitcoin,mm-s/bitcoin,jonasschnelli/bitcoin,particl/particl-core,domob1812/bitcoin,bitcoinknots/bitcoin,kallewoof/bitcoin,lateminer/bitcoin,yenliangl/bitcoin,andreaskern/bitcoin,ElementsProject/elements,Xekyo/bitcoin,JeremyRubin/bitcoin,achow101/bitcoin,alecalve/bitcoin,achow101/bitcoin,Xekyo/bitcoin,practicalswift/bitcoin,sipsorcery/bitcoin,Sjors/bitcoin,jonasschnelli/bitcoin,jlopp/statoshi,dscotese/bitcoin,mm-s/bitcoin,mruddy/bitcoin,fujicoin/fujicoin,sstone/bitcoin,yenliangl/bitcoin,bitcoin/bitcoin,mruddy/bitcoin,pataquets/namecoin-core,apoelstra/bitcoin,pataquets/namecoin-core,kallewoof/bitcoin,mm-s/bitcoin,rnicoll/bitcoin,sipsorcery/bitcoin,bitcoinsSG/bitcoin,sipsorcery/bitcoin,bitcoinknots/bitcoin,particl/particl-core,cdecker/bitcoin,mm-s/bitcoin,ElementsProject/elements,n1bor/bitcoin,tecnovert/particl-core,tecnovert/particl-core,dscotese/bitcoin,andreaskern/bitcoin,rnicoll/dogecoin,instagibbs/bitcoin,bitcoinsSG/bitcoin,GroestlCoin/bitcoin,jnewbery/bitcoin,Xekyo/bitcoin,alecalve/bitcoin,lateminer/bitcoin,Sjors/bitcoin,litecoin-project/litecoin,mruddy/bitcoin,fujicoin/fujicoin,cdecker/bitcoin,cdecker/bitcoin,dscotese/bitcoin,particl/particl-core,alecalve/bitcoin,sipsorcery/bitcoin,jamesob/bitcoin,GroestlCoin/bitcoin,yenliangl/bitcoin,rnicoll/bitcoin,andreaskern/bitcoin,mruddy/bitcoin,MeshCollider/bitcoin,achow101/bitcoin,ajtowns/bitcoin,jambolo/bitcoin,ajtowns/bitcoin,litecoin-project/litecoin,apoelstra/bitcoin,qtumproject/qtum,dscotese/bitcoin,mm-s/bitcoin,anditto/bitcoin,midnightmagic/bitcoin,apoelstra/bitcoin,bitcoinsSG/bitcoin,prusnak/bitcoin,cdecker/bitcoin,pataquets/namecoin-core,dscotese/bitcoin,ajtowns/bitcoin,prusnak/bitcoin,instagibbs/bitcoin,tecnovert/particl-core,kallewoof/bitcoin,MarcoFalke/bitcoin,rnicoll/bitcoin,jlopp/statoshi,tecnovert/particl-core,prusnak/bitcoin,qtumproject/qtum,fanquake/bitcoin,MarcoFalke/bitcoin,GroestlCoin/GroestlCoin,EthanHeilman/bitcoin,litecoin-project/litecoin,jambolo/bitcoin,namecoin/namecore,n1bor/bitcoin,pstratem/bitcoin,bitcoinknots/bitcoin,pstratem/bitcoin,bitcoinsSG/bitcoin,pataquets/namecoin-core,bitcoinknots/bitcoin,alecalve/bitcoin,cdecker/bitcoin,pataquets/namecoin-core
c++
## Code Before: // Copyright (c) 2009-2019 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include <test/fuzz/fuzz.h> #include <util/bip32.h> void test_one_input(const std::vector<uint8_t>& buffer) { const std::string keypath_str(buffer.begin(), buffer.end()); std::vector<uint32_t> keypath; (void)ParseHDKeypath(keypath_str, keypath); } ## Instruction: tests: Add fuzzing coverage for FormatHDKeypath(...) and WriteHDKeypath(...) ## Code After: // Copyright (c) 2009-2019 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include <test/fuzz/FuzzedDataProvider.h> #include <test/fuzz/fuzz.h> #include <test/fuzz/util.h> #include <util/bip32.h> #include <cstdint> #include <vector> void test_one_input(const std::vector<uint8_t>& buffer) { const std::string keypath_str(buffer.begin(), buffer.end()); std::vector<uint32_t> keypath; (void)ParseHDKeypath(keypath_str, keypath); FuzzedDataProvider fuzzed_data_provider(buffer.data(), buffer.size()); const std::vector<uint32_t> random_keypath = ConsumeRandomLengthIntegralVector<uint32_t>(fuzzed_data_provider); (void)FormatHDKeypath(random_keypath); (void)WriteHDKeypath(random_keypath); }
ef52c39df9a90401fc237383ef270360c3ef90f7
src/Ojs/JournalBundle/DataFixtures/Alice/article.yml
src/Ojs/JournalBundle/DataFixtures/Alice/article.yml
\Ojs\JournalBundle\Entity\Article: article{1..50}: doi: <regexify('\d{9}')> firstPage: <boolean(20)> isAnonymous: false journal: @journal* keywords: <text(10)>,<text(10)>,<text(10)> lastPage: <randomNumber(3)> pubdate: <dateTimeThisYear()> status: <boolean(80)> subjects: <text(85)>,<text(84)>,<text(83)> title: <text(255)> submitterId: @user*->id section: @section* issue: @issue*
\Ojs\JournalBundle\Entity\Article: article{1..50}: doi: <regexify('\d{9}')> firstPage: <boolean(20)> isAnonymous: false journal: @journal* keywords: <text(10)>,<text(10)>,<text(10)> lastPage: <randomNumber(3)> pubdate: <dateTimeThisYear()> status: 3 subjects: <text(85)>,<text(84)>,<text(83)> title: <text(255)> submitterId: @user*->id section: @section* issue: @issue*
Test fixed. JournalList limit updated.
Test fixed. JournalList limit updated.
YAML
mit
okulbilisim/ojs,beyzakokcan/ojs,okulbilisim/ojs,beyzakokcan/ojs,beyzakokcan/ojs,okulbilisim/ojs
yaml
## Code Before: \Ojs\JournalBundle\Entity\Article: article{1..50}: doi: <regexify('\d{9}')> firstPage: <boolean(20)> isAnonymous: false journal: @journal* keywords: <text(10)>,<text(10)>,<text(10)> lastPage: <randomNumber(3)> pubdate: <dateTimeThisYear()> status: <boolean(80)> subjects: <text(85)>,<text(84)>,<text(83)> title: <text(255)> submitterId: @user*->id section: @section* issue: @issue* ## Instruction: Test fixed. JournalList limit updated. ## Code After: \Ojs\JournalBundle\Entity\Article: article{1..50}: doi: <regexify('\d{9}')> firstPage: <boolean(20)> isAnonymous: false journal: @journal* keywords: <text(10)>,<text(10)>,<text(10)> lastPage: <randomNumber(3)> pubdate: <dateTimeThisYear()> status: 3 subjects: <text(85)>,<text(84)>,<text(83)> title: <text(255)> submitterId: @user*->id section: @section* issue: @issue*
4fd503b8a724c788a5129c0ee3794397518c6a7e
windows/build-foreign.bat
windows/build-foreign.bat
@echo off SET GENERATOR="Visual Studio 15 2017" SET GENERATOR64="Visual Studio 15 2017 Win64" cd ../foreign/ cd SPIRV-Tools mkdir build cd build cmake -G%GENERATOR% -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR64% -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. cd .. cd SPIRV-Cross mkdir build cd build cmake -G%GENERATOR% .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR64% .. cmake --build . cmake --build . --config Release cd .. cd .. cd ../windows
@echo off SET GENERATOR="Visual Studio 16 2019" cd ../foreign/ cd SPIRV-Tools mkdir build cd build cmake -G%GENERATOR% -A Win32 -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR% -A x64 -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. cd .. cd SPIRV-Cross mkdir build cd build cmake -G%GENERATOR% -A Win32 .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR% -A x64 .. cmake --build . cmake --build . --config Release cd .. cd .. cd ../windows
Update windows build bat for new CMake / Visual Studio
Update windows build bat for new CMake / Visual Studio
Batchfile
mit
turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo,turol/smaaDemo
batchfile
## Code Before: @echo off SET GENERATOR="Visual Studio 15 2017" SET GENERATOR64="Visual Studio 15 2017 Win64" cd ../foreign/ cd SPIRV-Tools mkdir build cd build cmake -G%GENERATOR% -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR64% -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. cd .. cd SPIRV-Cross mkdir build cd build cmake -G%GENERATOR% .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR64% .. cmake --build . cmake --build . --config Release cd .. cd .. cd ../windows ## Instruction: Update windows build bat for new CMake / Visual Studio ## Code After: @echo off SET GENERATOR="Visual Studio 16 2019" cd ../foreign/ cd SPIRV-Tools mkdir build cd build cmake -G%GENERATOR% -A Win32 -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR% -A x64 -DSPIRV-Headers_SOURCE_DIR=%cd%/../../SPIRV-Headers .. cmake --build . cmake --build . --config Release cd .. cd .. cd SPIRV-Cross mkdir build cd build cmake -G%GENERATOR% -A Win32 .. cmake --build . cmake --build . --config Release cd .. mkdir build64 cd build64 cmake -G%GENERATOR% -A x64 .. cmake --build . cmake --build . --config Release cd .. cd .. cd ../windows
4ad7cdb49249c3c75b10cc98aa54f97522006ef2
tests/Identicon/Functional/IndexTest.php
tests/Identicon/Functional/IndexTest.php
<?php namespace Identicon\Tests; use Silex\WebTestCase; class IndexTest extends WebTestCase { public function createApplication() { return require __DIR__ . "/../../../src/production.php"; } public function testLoadingIndexPage() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('html:contains("Identicon")')->count()); } public function testHeaderLink() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('a.navbar-brand')->count()); $host = $client->getServerParameter("HTTP_HOST"); $this->assertEquals("http://{$host}/", $crawler->filter('a.navbar-brand ')->attr("href")); } }
<?php namespace Identicon\Tests; use Silex\WebTestCase; class IndexTest extends WebTestCase { public function createApplication() { return require __DIR__ . "/../../../src/production.php"; } public function testLoadingIndexPage() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('html:contains("Identicon")')->count()); } public function testHtmlTitleContainsTheName() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $this->assertEquals("Identicons", $crawler->filter("html > head > title")->text()); } public function testHeaderLink() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('a.navbar-brand')->count()); $host = $client->getServerParameter("HTTP_HOST"); $this->assertEquals("http://{$host}/", $crawler->filter('a.navbar-brand ')->attr("href")); } }
Index page: title tag must contain "Identicons".
Index page: title tag must contain "Identicons".
PHP
mit
rmhdev/identicon,rmhdev/identicon
php
## Code Before: <?php namespace Identicon\Tests; use Silex\WebTestCase; class IndexTest extends WebTestCase { public function createApplication() { return require __DIR__ . "/../../../src/production.php"; } public function testLoadingIndexPage() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('html:contains("Identicon")')->count()); } public function testHeaderLink() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('a.navbar-brand')->count()); $host = $client->getServerParameter("HTTP_HOST"); $this->assertEquals("http://{$host}/", $crawler->filter('a.navbar-brand ')->attr("href")); } } ## Instruction: Index page: title tag must contain "Identicons". ## Code After: <?php namespace Identicon\Tests; use Silex\WebTestCase; class IndexTest extends WebTestCase { public function createApplication() { return require __DIR__ . "/../../../src/production.php"; } public function testLoadingIndexPage() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('html:contains("Identicon")')->count()); } public function testHtmlTitleContainsTheName() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $this->assertEquals("Identicons", $crawler->filter("html > head > title")->text()); } public function testHeaderLink() { $client = $this->createClient(); $crawler = $client->request("GET", "/"); $response = $client->getResponse(); $this->assertTrue($response->isSuccessful()); $this->assertGreaterThanOrEqual(1, $crawler->filter('a.navbar-brand')->count()); $host = $client->getServerParameter("HTTP_HOST"); $this->assertEquals("http://{$host}/", $crawler->filter('a.navbar-brand ')->attr("href")); } }
61e479b1966317df903561972eef1bd8001b626a
language/tests/regent/run_pass/inline_task_rawfields.rg
language/tests/regent/run_pass/inline_task_rawfields.rg
-- Copyright 2020 Stanford University -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. import "regent" local c = regentlib.c fspace Fields { A : double, B : double, C : double } __demand(__inline) task test(t : region(ispace(int1d), Fields)) where reads(t.B), writes(t.A) do var a = __fields(t.{A, B}) return a[0] end task main() var t = region(ispace(int1d, 2), Fields) fill(t.{A, B, C}, 0) var f = test(t) regentlib.assert(f == __fields(t.A)[0], "test failed") end regentlib.start(main)
-- Copyright 2020 Stanford University -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. import "regent" local c = regentlib.c fspace Fields { A : double, B : double, C : double, D : &double, } __demand(__inline) task test(t : region(ispace(int1d), Fields)) where reads(t.B), writes(t.A) do var a = __fields(t.{A, B}) return a[0] end __demand(__inline) task test2(t : region(ispace(int1d), Fields)) where reads(t.D) do var a = __fields(t.{D}) return a[0] end task main() var t = region(ispace(int1d, 2), Fields) fill(t.{A, B, C}, 0) var f = test(t) var g = test2(t) regentlib.assert(f == __fields(t.A)[0], "test failed") regentlib.assert(g == __fields(t.D)[0], "test failed") end regentlib.start(main)
Update the task inliner test
tests: Update the task inliner test
Rouge
apache-2.0
StanfordLegion/legion,StanfordLegion/legion,StanfordLegion/legion,StanfordLegion/legion,StanfordLegion/legion,StanfordLegion/legion,StanfordLegion/legion,StanfordLegion/legion
rouge
## Code Before: -- Copyright 2020 Stanford University -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. import "regent" local c = regentlib.c fspace Fields { A : double, B : double, C : double } __demand(__inline) task test(t : region(ispace(int1d), Fields)) where reads(t.B), writes(t.A) do var a = __fields(t.{A, B}) return a[0] end task main() var t = region(ispace(int1d, 2), Fields) fill(t.{A, B, C}, 0) var f = test(t) regentlib.assert(f == __fields(t.A)[0], "test failed") end regentlib.start(main) ## Instruction: tests: Update the task inliner test ## Code After: -- Copyright 2020 Stanford University -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. import "regent" local c = regentlib.c fspace Fields { A : double, B : double, C : double, D : &double, } __demand(__inline) task test(t : region(ispace(int1d), Fields)) where reads(t.B), writes(t.A) do var a = __fields(t.{A, B}) return a[0] end __demand(__inline) task test2(t : region(ispace(int1d), Fields)) where reads(t.D) do var a = __fields(t.{D}) return a[0] end task main() var t = region(ispace(int1d, 2), Fields) fill(t.{A, B, C}, 0) var f = test(t) var g = test2(t) regentlib.assert(f == __fields(t.A)[0], "test failed") regentlib.assert(g == __fields(t.D)[0], "test failed") end regentlib.start(main)
370726c0a28b67f9b92f49a92f300e3ee4554922
Transport/Transport.swift
Transport/Transport.swift
// // Transport.swift // Transport // // Created by Paul Young on 26/08/2014. // Copyright (c) 2014 CocoaFlow. All rights reserved. // import MessageTransfer public protocol Transport: MessageSenderWithReceiver { init(_ messageReceiver: MessageReceiverWithSender) }
// // Transport.swift // Transport // // Created by Paul Young on 26/08/2014. // Copyright (c) 2014 CocoaFlow. All rights reserved. // import MessageTransfer public protocol Transport: MessageSenderWithReceiver { }
Remove overly restrictive init method.
Remove overly restrictive init method. The intention was to require a transport to use a specific type of MessageReceiver via the init method. There seems to be no feasible alternative due to lack of support for circular references, or redefined properties in protocol inheritance.
Swift
apache-2.0
CocoaFlow/Transport,CocoaFlow/Transport
swift
## Code Before: // // Transport.swift // Transport // // Created by Paul Young on 26/08/2014. // Copyright (c) 2014 CocoaFlow. All rights reserved. // import MessageTransfer public protocol Transport: MessageSenderWithReceiver { init(_ messageReceiver: MessageReceiverWithSender) } ## Instruction: Remove overly restrictive init method. The intention was to require a transport to use a specific type of MessageReceiver via the init method. There seems to be no feasible alternative due to lack of support for circular references, or redefined properties in protocol inheritance. ## Code After: // // Transport.swift // Transport // // Created by Paul Young on 26/08/2014. // Copyright (c) 2014 CocoaFlow. All rights reserved. // import MessageTransfer public protocol Transport: MessageSenderWithReceiver { }
7161863e1574719e72de0265258ba03fa954c9fa
lib/kanji/application.rb
lib/kanji/application.rb
require "roda" require "roda/plugins/flow" require "dry-configurable" require "dry-monitor" module Kanji class Application < ::Roda extend Dry::Configurable setting :container, reader: true plugin :render, views: "app/views" plugin :error_handler plugin :flow def self.configure(&block) super.tap do use(container[:rack_monitor]) if container.config.listeners end end def self.resolve(name) container[name] end def self.[](name) container[name] end def self.root container.config.root end def notifications self.class[:notifications] end end end
require "roda" require "roda/plugins/flow" require "dry-configurable" module Kanji class Application < ::Roda extend Dry::Configurable setting :container, reader: true plugin :render, views: "app/views" plugin :error_handler plugin :flow def self.configure(&block) super.tap do use(container[:rack_monitor]) if container.config.listeners end end def self.resolve(name) container[name] end def self.[](name) container[name] end def self.root container.config.root end def notifications self.class[:notifications] end end end
Remove unneeded require of dry-monitor
Remove unneeded require of dry-monitor
Ruby
mit
dphaener/kanji,dphaener/kanji
ruby
## Code Before: require "roda" require "roda/plugins/flow" require "dry-configurable" require "dry-monitor" module Kanji class Application < ::Roda extend Dry::Configurable setting :container, reader: true plugin :render, views: "app/views" plugin :error_handler plugin :flow def self.configure(&block) super.tap do use(container[:rack_monitor]) if container.config.listeners end end def self.resolve(name) container[name] end def self.[](name) container[name] end def self.root container.config.root end def notifications self.class[:notifications] end end end ## Instruction: Remove unneeded require of dry-monitor ## Code After: require "roda" require "roda/plugins/flow" require "dry-configurable" module Kanji class Application < ::Roda extend Dry::Configurable setting :container, reader: true plugin :render, views: "app/views" plugin :error_handler plugin :flow def self.configure(&block) super.tap do use(container[:rack_monitor]) if container.config.listeners end end def self.resolve(name) container[name] end def self.[](name) container[name] end def self.root container.config.root end def notifications self.class[:notifications] end end end
78296e7326dd9faedcc850e2670563c40bfabe3f
spec/controllers/vm_cloud_controller/trees_spec.rb
spec/controllers/vm_cloud_controller/trees_spec.rb
describe VmCloudController do render_views before :each do set_user_privileges EvmSpecHelper.create_guid_miq_server_zone end context "#tree_select" do [ %w(Instances instances_tree), %w(Images images_tree), %w(Instances instances_filter_tree), %w(Images images_filter_tree) ].each do |elements, tree| it "renders list of #{elements} for #{tree} root node" do FactoryGirl.create(:vm_openstack) FactoryGirl.create(:template_openstack) session[:settings] = {} seed_session_trees('vm_cloud', tree.to_sym) post :tree_select, :params => { :id => 'root', :format => :js } expect(response).to render_template('layouts/gtl/_list') expect(response.status).to eq(200) end end it "renders Instance details for Instance node" do instance = FactoryGirl.create(:vm_openstack) session[:settings] = {} seed_session_trees('vm_cloud', 'instances_tree') post :tree_select, :params => { :id => "v-#{instance.compressed_id}", :format => :js } expect(response).to render_template('vm_cloud/_main') expect(response).to render_template('shared/summary/_textual_tags') expect(response.status).to eq(200) end end end
describe VmCloudController do render_views before :each do set_user_privileges EvmSpecHelper.create_guid_miq_server_zone end context "#tree_select" do [ %w(Instances instances_tree), %w(Images images_tree), %w(Instances instances_filter_tree), %w(Images images_filter_tree) ].each do |elements, tree| it "renders list of #{elements} for #{tree} root node" do FactoryGirl.create(:vm_openstack) FactoryGirl.create(:template_openstack) session[:settings] = {} seed_session_trees('vm_cloud', tree.to_sym) post :tree_select, :params => { :id => 'root', :format => :js } expect(response).to render_template('layouts/gtl/_list') expect(response.status).to eq(200) end end [ %w(vm_openstack Openstack), %w(vm_azure Azure), %w(vm_google Google), %w(vm_amazon Amazon) ].each do |instance, name| it "renders Instance details for #{name} node" do instance = FactoryGirl.create(instance.to_sym) session[:settings] = {} seed_session_trees('vm_cloud', 'instances_tree') post :tree_select, :params => { :id => "v-#{instance.compressed_id}", :format => :js } expect(response).to render_template('vm_cloud/_main') expect(response).to render_template('shared/summary/_textual_tags') expect(response.status).to eq(200) end end end end
Add specs for cloud instance display in explorer.
Add specs for cloud instance display in explorer.
Ruby
apache-2.0
branic/manageiq,hstastna/manageiq,maas-ufcg/manageiq,ilackarms/manageiq,mfeifer/manageiq,romanblanco/manageiq,skateman/manageiq,NickLaMuro/manageiq,jrafanie/manageiq,lpichler/manageiq,durandom/manageiq,NaNi-Z/manageiq,jameswnl/manageiq,juliancheal/manageiq,aufi/manageiq,lpichler/manageiq,branic/manageiq,romanblanco/manageiq,mzazrivec/manageiq,djberg96/manageiq,jrafanie/manageiq,gmcculloug/manageiq,kbrock/manageiq,chessbyte/manageiq,jvlcek/manageiq,mzazrivec/manageiq,mresti/manageiq,ailisp/manageiq,NaNi-Z/manageiq,yaacov/manageiq,ManageIQ/manageiq,durandom/manageiq,ilackarms/manageiq,jntullo/manageiq,mfeifer/manageiq,matobet/manageiq,borod108/manageiq,jntullo/manageiq,hstastna/manageiq,billfitzgerald0120/manageiq,syncrou/manageiq,romaintb/manageiq,jntullo/manageiq,fbladilo/manageiq,romanblanco/manageiq,gmcculloug/manageiq,mkanoor/manageiq,mfeifer/manageiq,tinaafitz/manageiq,mresti/manageiq,maas-ufcg/manageiq,d-m-u/manageiq,tinaafitz/manageiq,djberg96/manageiq,israel-hdez/manageiq,matobet/manageiq,skateman/manageiq,yaacov/manageiq,mkanoor/manageiq,NaNi-Z/manageiq,aufi/manageiq,romaintb/manageiq,skateman/manageiq,jrafanie/manageiq,billfitzgerald0120/manageiq,syncrou/manageiq,romaintb/manageiq,maas-ufcg/manageiq,fbladilo/manageiq,ailisp/manageiq,romaintb/manageiq,gerikis/manageiq,pkomanek/manageiq,juliancheal/manageiq,maas-ufcg/manageiq,matobet/manageiq,KevinLoiseau/manageiq,branic/manageiq,NickLaMuro/manageiq,gerikis/manageiq,djberg96/manageiq,andyvesel/manageiq,josejulio/manageiq,tzumainn/manageiq,mkanoor/manageiq,jameswnl/manageiq,tinaafitz/manageiq,ailisp/manageiq,skateman/manageiq,israel-hdez/manageiq,gmcculloug/manageiq,andyvesel/manageiq,mresti/manageiq,djberg96/manageiq,andyvesel/manageiq,pkomanek/manageiq,juliancheal/manageiq,aufi/manageiq,josejulio/manageiq,josejulio/manageiq,tzumainn/manageiq,NickLaMuro/manageiq,israel-hdez/manageiq,mfeifer/manageiq,borod108/manageiq,mzazrivec/manageiq,jvlcek/manageiq,chessbyte/manageiq,chessbyte/manageiq,durandom/manageiq,ilackarms/manageiq,jrafanie/manageiq,hstastna/manageiq,romaintb/manageiq,romanblanco/manageiq,agrare/manageiq,billfitzgerald0120/manageiq,tzumainn/manageiq,d-m-u/manageiq,kbrock/manageiq,juliancheal/manageiq,andyvesel/manageiq,pkomanek/manageiq,kbrock/manageiq,yaacov/manageiq,NaNi-Z/manageiq,fbladilo/manageiq,branic/manageiq,jntullo/manageiq,gmcculloug/manageiq,ManageIQ/manageiq,romaintb/manageiq,gerikis/manageiq,josejulio/manageiq,maas-ufcg/manageiq,aufi/manageiq,d-m-u/manageiq,mzazrivec/manageiq,NickLaMuro/manageiq,gerikis/manageiq,durandom/manageiq,KevinLoiseau/manageiq,borod108/manageiq,ManageIQ/manageiq,fbladilo/manageiq,kbrock/manageiq,agrare/manageiq,jvlcek/manageiq,hstastna/manageiq,KevinLoiseau/manageiq,ManageIQ/manageiq,KevinLoiseau/manageiq,KevinLoiseau/manageiq,lpichler/manageiq,matobet/manageiq,agrare/manageiq,tinaafitz/manageiq,israel-hdez/manageiq,mkanoor/manageiq,chessbyte/manageiq,ilackarms/manageiq,syncrou/manageiq,tzumainn/manageiq,lpichler/manageiq,maas-ufcg/manageiq,jameswnl/manageiq,yaacov/manageiq,pkomanek/manageiq,ailisp/manageiq,jameswnl/manageiq,mresti/manageiq,KevinLoiseau/manageiq,jvlcek/manageiq,borod108/manageiq,syncrou/manageiq,d-m-u/manageiq,agrare/manageiq,billfitzgerald0120/manageiq
ruby
## Code Before: describe VmCloudController do render_views before :each do set_user_privileges EvmSpecHelper.create_guid_miq_server_zone end context "#tree_select" do [ %w(Instances instances_tree), %w(Images images_tree), %w(Instances instances_filter_tree), %w(Images images_filter_tree) ].each do |elements, tree| it "renders list of #{elements} for #{tree} root node" do FactoryGirl.create(:vm_openstack) FactoryGirl.create(:template_openstack) session[:settings] = {} seed_session_trees('vm_cloud', tree.to_sym) post :tree_select, :params => { :id => 'root', :format => :js } expect(response).to render_template('layouts/gtl/_list') expect(response.status).to eq(200) end end it "renders Instance details for Instance node" do instance = FactoryGirl.create(:vm_openstack) session[:settings] = {} seed_session_trees('vm_cloud', 'instances_tree') post :tree_select, :params => { :id => "v-#{instance.compressed_id}", :format => :js } expect(response).to render_template('vm_cloud/_main') expect(response).to render_template('shared/summary/_textual_tags') expect(response.status).to eq(200) end end end ## Instruction: Add specs for cloud instance display in explorer. ## Code After: describe VmCloudController do render_views before :each do set_user_privileges EvmSpecHelper.create_guid_miq_server_zone end context "#tree_select" do [ %w(Instances instances_tree), %w(Images images_tree), %w(Instances instances_filter_tree), %w(Images images_filter_tree) ].each do |elements, tree| it "renders list of #{elements} for #{tree} root node" do FactoryGirl.create(:vm_openstack) FactoryGirl.create(:template_openstack) session[:settings] = {} seed_session_trees('vm_cloud', tree.to_sym) post :tree_select, :params => { :id => 'root', :format => :js } expect(response).to render_template('layouts/gtl/_list') expect(response.status).to eq(200) end end [ %w(vm_openstack Openstack), %w(vm_azure Azure), %w(vm_google Google), %w(vm_amazon Amazon) ].each do |instance, name| it "renders Instance details for #{name} node" do instance = FactoryGirl.create(instance.to_sym) session[:settings] = {} seed_session_trees('vm_cloud', 'instances_tree') post :tree_select, :params => { :id => "v-#{instance.compressed_id}", :format => :js } expect(response).to render_template('vm_cloud/_main') expect(response).to render_template('shared/summary/_textual_tags') expect(response.status).to eq(200) end end end end
3f666384c8c38824b61bdcb96df6ace61ac8329a
README.rst
README.rst
********************************************** ``vecrec`` --- 2D vector and rectangle classes ********************************************** .. image:: https://travis-ci.org/kxgames/vecrec.svg?branch=master :target: https://travis-ci.org/kxgames/vecrec This package provides 2D vector and rectangle classes. Installation ============ The ``vecrec`` module is pure-python, dependency-free, and available from PyPI:: $ pip install vecrec Basic Usage =========== In lieu of complete API documentation, here are a few examples showing how to construct and use use the ``Vector`` and ``Rect`` classes provided by this package:: >>> from vecrec import Vector, Rect >>> a = Vector(1, 2) >>> b = Vector(3, 4) >>> a + b Vector(4, 6) Rectangles are more commonly constructed using factory methods:: >>> Rect.from_size(8, 11) Rect(0, 0, 8, 11) >>> Rect.from_center(a, 1, 1) Rect(0, 1, 1, 1)
********************************************** ``vecrec`` --- 2D vector and rectangle classes ********************************************** This package provides 2D vector and rectangle classes. These classes were written to be used in games, so they have some methods that conveniently tie into ``pyglet`` and ``pygame``, but for the most part they are quite general and could be used for almost anything. .. image:: https://travis-ci.org/kxgames/vecrec.svg?branch=master :target: https://travis-ci.org/kxgames/vecrec Installation ============ The ``vecrec`` module is pure-python, dependency-free, and available from PyPI:: $ pip install vecrec Basic Usage =========== In lieu of complete API documentation, here are a few examples showing how to construct and use use the ``Vector`` and ``Rect`` classes provided by this package:: >>> from vecrec import Vector, Rect >>> a = Vector(1, 2) >>> b = Vector(3, 4) >>> a + b Vector(4, 6) Rectangles are more commonly constructed using factory methods:: >>> Rect.from_size(8, 11) Rect(0, 0, 8, 11) >>> Rect.from_center(a, 1, 1) Rect(0, 1, 1, 1)
Move the Travis CI badge.
Move the Travis CI badge.
reStructuredText
mit
kxgames/vecrec,kxgames/vecrec
restructuredtext
## Code Before: ********************************************** ``vecrec`` --- 2D vector and rectangle classes ********************************************** .. image:: https://travis-ci.org/kxgames/vecrec.svg?branch=master :target: https://travis-ci.org/kxgames/vecrec This package provides 2D vector and rectangle classes. Installation ============ The ``vecrec`` module is pure-python, dependency-free, and available from PyPI:: $ pip install vecrec Basic Usage =========== In lieu of complete API documentation, here are a few examples showing how to construct and use use the ``Vector`` and ``Rect`` classes provided by this package:: >>> from vecrec import Vector, Rect >>> a = Vector(1, 2) >>> b = Vector(3, 4) >>> a + b Vector(4, 6) Rectangles are more commonly constructed using factory methods:: >>> Rect.from_size(8, 11) Rect(0, 0, 8, 11) >>> Rect.from_center(a, 1, 1) Rect(0, 1, 1, 1) ## Instruction: Move the Travis CI badge. ## Code After: ********************************************** ``vecrec`` --- 2D vector and rectangle classes ********************************************** This package provides 2D vector and rectangle classes. These classes were written to be used in games, so they have some methods that conveniently tie into ``pyglet`` and ``pygame``, but for the most part they are quite general and could be used for almost anything. .. image:: https://travis-ci.org/kxgames/vecrec.svg?branch=master :target: https://travis-ci.org/kxgames/vecrec Installation ============ The ``vecrec`` module is pure-python, dependency-free, and available from PyPI:: $ pip install vecrec Basic Usage =========== In lieu of complete API documentation, here are a few examples showing how to construct and use use the ``Vector`` and ``Rect`` classes provided by this package:: >>> from vecrec import Vector, Rect >>> a = Vector(1, 2) >>> b = Vector(3, 4) >>> a + b Vector(4, 6) Rectangles are more commonly constructed using factory methods:: >>> Rect.from_size(8, 11) Rect(0, 0, 8, 11) >>> Rect.from_center(a, 1, 1) Rect(0, 1, 1, 1)
401de0bd95ed6082cc1b4fd647bb95e4b054d391
docs/releasenotes/1.7.16.txt
docs/releasenotes/1.7.16.txt
================================= Review Board 1.7.16 Release Notes ================================= **Release date**: October 11, 2013 New Features ============ * Added two new hooks for extensibility: HeaderActionHook, and HeaderDropdownActionHook. These can be used to inject new entries into the top bar, alongside the User and Support items. Patch by Mike Conley. Bug Fixes ========= * Fixed a breakage when accessing the Review Group Users resource. Contributors ============ * Christian Hammond * Mike Conley .. comment: vim: ft=rst et
================================= Review Board 1.7.16 Release Notes ================================= **Release date**: October 11, 2013 New Features ============ * Added two new hooks for extensibility: HeaderActionHook, and HeaderDropdownActionHook. These can be used to inject new entries into the top bar, alongside the User and Support items. Patch by Mike Conley. Bug Fixes ========= * Fixed a breakage when accessing the Review Group Users resource. * Fixed a packaging issue for the Python 2.6 builds. Contributors ============ * Christian Hammond * Mike Conley .. comment: vim: ft=rst et
Add the missing release notes entry for the packaging problem.
Add the missing release notes entry for the packaging problem.
Text
mit
1tush/reviewboard,sgallagher/reviewboard,chipx86/reviewboard,davidt/reviewboard,bkochendorfer/reviewboard,bkochendorfer/reviewboard,beol/reviewboard,custode/reviewboard,KnowNo/reviewboard,brennie/reviewboard,1tush/reviewboard,1tush/reviewboard,reviewboard/reviewboard,reviewboard/reviewboard,KnowNo/reviewboard,chipx86/reviewboard,davidt/reviewboard,sgallagher/reviewboard,beol/reviewboard,chipx86/reviewboard,beol/reviewboard,KnowNo/reviewboard,beol/reviewboard,sgallagher/reviewboard,custode/reviewboard,custode/reviewboard,1tush/reviewboard,1tush/reviewboard,sgallagher/reviewboard,1tush/reviewboard,1tush/reviewboard,chipx86/reviewboard,custode/reviewboard,brennie/reviewboard,1tush/reviewboard,bkochendorfer/reviewboard,bkochendorfer/reviewboard,davidt/reviewboard,1tush/reviewboard,KnowNo/reviewboard,brennie/reviewboard,brennie/reviewboard,davidt/reviewboard,reviewboard/reviewboard,reviewboard/reviewboard
text
## Code Before: ================================= Review Board 1.7.16 Release Notes ================================= **Release date**: October 11, 2013 New Features ============ * Added two new hooks for extensibility: HeaderActionHook, and HeaderDropdownActionHook. These can be used to inject new entries into the top bar, alongside the User and Support items. Patch by Mike Conley. Bug Fixes ========= * Fixed a breakage when accessing the Review Group Users resource. Contributors ============ * Christian Hammond * Mike Conley .. comment: vim: ft=rst et ## Instruction: Add the missing release notes entry for the packaging problem. ## Code After: ================================= Review Board 1.7.16 Release Notes ================================= **Release date**: October 11, 2013 New Features ============ * Added two new hooks for extensibility: HeaderActionHook, and HeaderDropdownActionHook. These can be used to inject new entries into the top bar, alongside the User and Support items. Patch by Mike Conley. Bug Fixes ========= * Fixed a breakage when accessing the Review Group Users resource. * Fixed a packaging issue for the Python 2.6 builds. Contributors ============ * Christian Hammond * Mike Conley .. comment: vim: ft=rst et
58a0106e0510123ac329fdc90fa5ebac7f80ecc0
sli/acceptance-tests/test/features/ingestion/features/ingestion_indexValidation.feature
sli/acceptance-tests/test/features/ingestion/features/ingestion_indexValidation.feature
@RALLY_US3478 Feature: Ingestion Index Validation Test Scenario: Verify if Indexes are present Given the log directory contains "ingestion.log" file Then I should see either "Index verified" or "Index missing" following IngestionRouteBuilder in "ingestion.log" file
@RALLY_US3478 Feature: Ingestion Index Validation Test Scenario: Verify if Indexes are present Given the log directory contains "ingestion.log" file Then I should see either "CORE_0018" or "CORE_0038" following IngestionRouteBuilder in "ingestion.log" file
Update A/T to only check for message codes.
[US4914] Update A/T to only check for message codes.
Cucumber
apache-2.0
inbloom/secure-data-service,inbloom/secure-data-service,inbloom/secure-data-service,inbloom/secure-data-service,inbloom/secure-data-service
cucumber
## Code Before: @RALLY_US3478 Feature: Ingestion Index Validation Test Scenario: Verify if Indexes are present Given the log directory contains "ingestion.log" file Then I should see either "Index verified" or "Index missing" following IngestionRouteBuilder in "ingestion.log" file ## Instruction: [US4914] Update A/T to only check for message codes. ## Code After: @RALLY_US3478 Feature: Ingestion Index Validation Test Scenario: Verify if Indexes are present Given the log directory contains "ingestion.log" file Then I should see either "CORE_0018" or "CORE_0038" following IngestionRouteBuilder in "ingestion.log" file
97a30d662f60aa4b4d2f04fc4686cd277092d434
app/Template/project_header/views.php
app/Template/project_header/views.php
<ul class="views"> <li <?= $this->app->checkMenuSelection('ProjectOverviewController') ?>> <?= $this->url->icon('eye', t('Overview'), 'ProjectOverviewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-overview', t('Keyboard shortcut: "%s"', 'v o')) ?> </li> <li <?= $this->app->checkMenuSelection('BoardViewController') ?>> <?= $this->url->icon('th', t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-board', t('Keyboard shortcut: "%s"', 'v b')) ?> </li> <li <?= $this->app->checkMenuSelection('TaskListController') ?>> <?= $this->url->icon('list', t('List'), 'TaskListController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-listing', t('Keyboard shortcut: "%s"', 'v l')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher', array('project' => $project, 'filters' => $filters)) ?> </ul>
<ul class="views"> <?= $this->hook->render('template:project-header:view-switcher-before-project-overview', array('project' => $project, 'filters' => $filters)) ?> <li <?= $this->app->checkMenuSelection('ProjectOverviewController') ?>> <?= $this->url->icon('eye', t('Overview'), 'ProjectOverviewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-overview', t('Keyboard shortcut: "%s"', 'v o')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher-before-board-view', array('project' => $project, 'filters' => $filters)) ?> <li <?= $this->app->checkMenuSelection('BoardViewController') ?>> <?= $this->url->icon('th', t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-board', t('Keyboard shortcut: "%s"', 'v b')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher-before-task-list', array('project' => $project, 'filters' => $filters)) ?> <li <?= $this->app->checkMenuSelection('TaskListController') ?>> <?= $this->url->icon('list', t('List'), 'TaskListController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-listing', t('Keyboard shortcut: "%s"', 'v l')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher', array('project' => $project, 'filters' => $filters)) ?> </ul>
Add new plugin hooks in view switcher
Add new plugin hooks in view switcher
PHP
mit
BlueTeck/kanboard,renothing/kanboard,BlueTeck/kanboard,kanboard/kanboard,libin/kanboard,BlueTeck/kanboard,kanboard/kanboard,libin/kanboard,renothing/kanboard,kanboard/kanboard,renothing/kanboard
php
## Code Before: <ul class="views"> <li <?= $this->app->checkMenuSelection('ProjectOverviewController') ?>> <?= $this->url->icon('eye', t('Overview'), 'ProjectOverviewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-overview', t('Keyboard shortcut: "%s"', 'v o')) ?> </li> <li <?= $this->app->checkMenuSelection('BoardViewController') ?>> <?= $this->url->icon('th', t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-board', t('Keyboard shortcut: "%s"', 'v b')) ?> </li> <li <?= $this->app->checkMenuSelection('TaskListController') ?>> <?= $this->url->icon('list', t('List'), 'TaskListController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-listing', t('Keyboard shortcut: "%s"', 'v l')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher', array('project' => $project, 'filters' => $filters)) ?> </ul> ## Instruction: Add new plugin hooks in view switcher ## Code After: <ul class="views"> <?= $this->hook->render('template:project-header:view-switcher-before-project-overview', array('project' => $project, 'filters' => $filters)) ?> <li <?= $this->app->checkMenuSelection('ProjectOverviewController') ?>> <?= $this->url->icon('eye', t('Overview'), 'ProjectOverviewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-overview', t('Keyboard shortcut: "%s"', 'v o')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher-before-board-view', array('project' => $project, 'filters' => $filters)) ?> <li <?= $this->app->checkMenuSelection('BoardViewController') ?>> <?= $this->url->icon('th', t('Board'), 'BoardViewController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-board', t('Keyboard shortcut: "%s"', 'v b')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher-before-task-list', array('project' => $project, 'filters' => $filters)) ?> <li <?= $this->app->checkMenuSelection('TaskListController') ?>> <?= $this->url->icon('list', t('List'), 'TaskListController', 'show', array('project_id' => $project['id'], 'search' => $filters['search']), false, 'view-listing', t('Keyboard shortcut: "%s"', 'v l')) ?> </li> <?= $this->hook->render('template:project-header:view-switcher', array('project' => $project, 'filters' => $filters)) ?> </ul>
dffb1b441885627bb2242952eb31036b1177269e
inc/const.inc.php
inc/const.inc.php
<?php /* * Site constants * * To change constants define them in config.inc.php */ /* SYSTEM */ if(!defined('STANDARD_URL')) define('STANDARD_URL','http://felixonline.co.uk/'); // standard site url if(!defined('ADMIN_URL')) define('ADMIN_URL','http://felixonline.co.uk/engine/'); // url of engine page if(!defined('PRODUCTION_FLAG')) define('PRODUCTION_FLAG', true); // if set to true css and js will be minified etc.. if(!defined('AUTHENTICATION_SERVER')) define('AUTHENTICATION_SERVER','dougal.union.ic.ac.uk'); // authentication server if(!defined('AUTHENTICATION_PATH')) define('AUTHENTICATION_PATH','https://dougal.union.ic.ac.uk/media/felix/'); // authentication path
<?php /* * Site constants * * To change constants define them in config.inc.php */ /* SYSTEM */ if(!defined('STANDARD_URL')) define('STANDARD_URL','http://felixonline.co.uk/'); // standard site url if(!defined('ADMIN_URL')) define('ADMIN_URL','http://felixonline.co.uk/engine/'); // url of engine page if(!defined('PRODUCTION_FLAG')) define('PRODUCTION_FLAG', true); // if set to true css and js will be minified etc. if(!defined('LOCAL')) define('LOCAL', false); // if true then site is hosted locally - don't use pam_auth etc. if(!defined('AUTHENTICATION_SERVER')) define('AUTHENTICATION_SERVER','dougal.union.ic.ac.uk'); // authentication server if(!defined('AUTHENTICATION_PATH')) define('AUTHENTICATION_PATH','https://dougal.union.ic.ac.uk/media/felix/'); // authentication path
Define local as false if not set
Define local as false if not set
PHP
mit
FelixOnline/FelixOnline,FelixOnline/FelixOnline,FelixOnline/FelixOnline
php
## Code Before: <?php /* * Site constants * * To change constants define them in config.inc.php */ /* SYSTEM */ if(!defined('STANDARD_URL')) define('STANDARD_URL','http://felixonline.co.uk/'); // standard site url if(!defined('ADMIN_URL')) define('ADMIN_URL','http://felixonline.co.uk/engine/'); // url of engine page if(!defined('PRODUCTION_FLAG')) define('PRODUCTION_FLAG', true); // if set to true css and js will be minified etc.. if(!defined('AUTHENTICATION_SERVER')) define('AUTHENTICATION_SERVER','dougal.union.ic.ac.uk'); // authentication server if(!defined('AUTHENTICATION_PATH')) define('AUTHENTICATION_PATH','https://dougal.union.ic.ac.uk/media/felix/'); // authentication path ## Instruction: Define local as false if not set ## Code After: <?php /* * Site constants * * To change constants define them in config.inc.php */ /* SYSTEM */ if(!defined('STANDARD_URL')) define('STANDARD_URL','http://felixonline.co.uk/'); // standard site url if(!defined('ADMIN_URL')) define('ADMIN_URL','http://felixonline.co.uk/engine/'); // url of engine page if(!defined('PRODUCTION_FLAG')) define('PRODUCTION_FLAG', true); // if set to true css and js will be minified etc. if(!defined('LOCAL')) define('LOCAL', false); // if true then site is hosted locally - don't use pam_auth etc. if(!defined('AUTHENTICATION_SERVER')) define('AUTHENTICATION_SERVER','dougal.union.ic.ac.uk'); // authentication server if(!defined('AUTHENTICATION_PATH')) define('AUTHENTICATION_PATH','https://dougal.union.ic.ac.uk/media/felix/'); // authentication path
345160942e9504de8d614d45fa48e4bf20859a41
src/instantetymonline/client.cljs
src/instantetymonline/client.cljs
(ns ^:figwheel-always instantetymonline.client (:require [reagent.core :as r] [instantetymonline.dict :refer [dict]])) (enable-console-print!) (defn etym-lookup [] (let [local (r/atom {:word ""})] ;; not included in render (fn [] ;; render from here (let [word (get @local :word)] [:div.center [:form [:input.h2 {:id "etym" :type "text" :value word :on-change (fn [e] (reset! local {:word (-> e .-target .-value)}))}]] [:div [:p (get dict word)]]])))) (defn main-component [] [:div [:h1.center "Etymologically delicious"] [etym-lookup]]) (r/render-component [main-component] (. js/document (getElementById "app")))
(ns ^:figwheel-always instantetymonline.client (:require [reagent.core :as r] [instantetymonline.dict :refer [dict]])) (enable-console-print!) (defn etym-lookup [] (let [local (r/atom {:word ""})] ;; not included in render (fn [] ;; render from here (let [word (get @local :word)] [:div [:form [:input.h2 {:id "etym" :type "text" :value word :on-change (fn [e] (reset! local {:word (-> e .-target .-value)}))}]] [:br] [:p {:style {"max-width" "35em"}} (get dict word)]])))) (defn main-component [] [:div.p1 [:h1 "Etym Deli"] [etym-lookup]]) (r/render-component [main-component] (. js/document (getElementById "app")))
Make design a bit more readable
Make design a bit more readable
Clojure
epl-1.0
oskarth/instantetymonline,oskarth/instantetymonline,oskarth/instantetymonline
clojure
## Code Before: (ns ^:figwheel-always instantetymonline.client (:require [reagent.core :as r] [instantetymonline.dict :refer [dict]])) (enable-console-print!) (defn etym-lookup [] (let [local (r/atom {:word ""})] ;; not included in render (fn [] ;; render from here (let [word (get @local :word)] [:div.center [:form [:input.h2 {:id "etym" :type "text" :value word :on-change (fn [e] (reset! local {:word (-> e .-target .-value)}))}]] [:div [:p (get dict word)]]])))) (defn main-component [] [:div [:h1.center "Etymologically delicious"] [etym-lookup]]) (r/render-component [main-component] (. js/document (getElementById "app"))) ## Instruction: Make design a bit more readable ## Code After: (ns ^:figwheel-always instantetymonline.client (:require [reagent.core :as r] [instantetymonline.dict :refer [dict]])) (enable-console-print!) (defn etym-lookup [] (let [local (r/atom {:word ""})] ;; not included in render (fn [] ;; render from here (let [word (get @local :word)] [:div [:form [:input.h2 {:id "etym" :type "text" :value word :on-change (fn [e] (reset! local {:word (-> e .-target .-value)}))}]] [:br] [:p {:style {"max-width" "35em"}} (get dict word)]])))) (defn main-component [] [:div.p1 [:h1 "Etym Deli"] [etym-lookup]]) (r/render-component [main-component] (. js/document (getElementById "app")))
33898e36b3e844d116066eae39b895d6e052a271
test/integration/console.test.js
test/integration/console.test.js
import {browser} from '../mini-testium-mocha'; import assert from 'assertive'; describe('console', () => { before(browser.beforeHook); before(async () => { await browser.navigateTo('/'); assert.equal(200, await browser.getStatusCode()); }); // Each browser fails to implement the WebDriver spec // for console.logs differently. // Use at your own risk. it('can all be retrieved', async () => { const { browserName } = await browser.sessionCapabilities(); let logs; switch (browserName) { case 'firefox': // firefox ignores this entirely break; case 'chrome': logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); logs = await browser.getConsoleLogs(); assert.equal(0, logs.length); await browser.clickOn('#log-button'); logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; default: logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; } }); });
import {browser} from '../mini-testium-mocha'; import assert from 'assertive'; describe('console', () => { before(browser.beforeHook); before(async () => { await browser.navigateTo('/'); assert.equal(200, await browser.getStatusCode()); }); // Each browser fails to implement the WebDriver spec // for console.logs differently. // Use at your own risk. it('can all be retrieved', async () => { const { browserName } = browser.capabilities; let logs; switch (browserName) { case 'firefox': // firefox ignores this entirely break; case 'chrome': logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); logs = await browser.getConsoleLogs(); assert.equal(0, logs.length); await browser.clickOn('#log-button'); logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; default: logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; } }); });
Make use of the stored capabilities
Make use of the stored capabilities
JavaScript
bsd-3-clause
testiumjs/testium-driver-wd
javascript
## Code Before: import {browser} from '../mini-testium-mocha'; import assert from 'assertive'; describe('console', () => { before(browser.beforeHook); before(async () => { await browser.navigateTo('/'); assert.equal(200, await browser.getStatusCode()); }); // Each browser fails to implement the WebDriver spec // for console.logs differently. // Use at your own risk. it('can all be retrieved', async () => { const { browserName } = await browser.sessionCapabilities(); let logs; switch (browserName) { case 'firefox': // firefox ignores this entirely break; case 'chrome': logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); logs = await browser.getConsoleLogs(); assert.equal(0, logs.length); await browser.clickOn('#log-button'); logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; default: logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; } }); }); ## Instruction: Make use of the stored capabilities ## Code After: import {browser} from '../mini-testium-mocha'; import assert from 'assertive'; describe('console', () => { before(browser.beforeHook); before(async () => { await browser.navigateTo('/'); assert.equal(200, await browser.getStatusCode()); }); // Each browser fails to implement the WebDriver spec // for console.logs differently. // Use at your own risk. it('can all be retrieved', async () => { const { browserName } = browser.capabilities; let logs; switch (browserName) { case 'firefox': // firefox ignores this entirely break; case 'chrome': logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); logs = await browser.getConsoleLogs(); assert.equal(0, logs.length); await browser.clickOn('#log-button'); logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; default: logs = await browser.getConsoleLogs(); assert.truthy('console.logs length', logs.length > 0); break; } }); });
c0cc1f29bfe8ea30d9fb819919189565850d9777
src/content/homepage/charts/second-chart/convert-msaxlsx-to-html.sh
src/content/homepage/charts/second-chart/convert-msaxlsx-to-html.sh
if [ $# -ne 1 ]; then echo "usage: $0 <xlsx-filename>" exit 1 fi # https://github.com/dilshod/xlsx2csv (this gracefully handles unicode nastiness, thankfully). pip install xlsx2csv xlsx2csv -d '|' $1 tmp-msa.csv echo '<select name="hmda_chart_2_msa" id="hmda_chart_2_msa"> <option selected value="CBSA00000">U.S. Total</option>' > msa-dropdown.html awk -F "|" '{ if(NR>1){print("<option value=\"CBSA"$1"\">"$2"</option>")}}' tmp-msa.csv >> msa-dropdown.html echo '</select>' >> msa-dropdown.html echo 'successfully created msa-dropdown.html' # cleanup tmp file rm -f tmp-msa.csv
HTMLDROPDOWN_FILE="msa-dropdown.html" if [ $# -ne 1 ]; then echo "usage: $0 <xlsx-filename>" exit 1 fi # https://github.com/dilshod/xlsx2csv (this gracefully handles unicode nastiness, thankfully). TMPCSV="tmp-msa.csv" xlsx2csv -d '|' $1 $TMPCSV 2> /dev/null || { echo >&2 "'xlsx2csv' is required for this script to execute. To install, run: pip install xlsx2csv Note that root access may be required to run pip commands. Aborting."; exit 1; } echo '<select name="hmda_chart_2_msa" id="hmda_chart_2_msa"> <option selected value="CBSA00000">U.S. Total</option>' > $HTMLDROPDOWN_FILE awk -F "|" '{ if(NR>1){print("<option value=\"CBSA"$1"\">"$2"</option>")}}' $TMPCSV >> $HTMLDROPDOWN_FILE echo '</select>' >> $HTMLDROPDOWN_FILE echo 'successfully created msa-dropdown.html' # cleanup tmp file rm -f $TMPCSV
Remove pip install from script and make filesnames vars.
Remove pip install from script and make filesnames vars.
Shell
cc0-1.0
kave/hmda-explorer,sleitner/hmda-explorer,m3brown/hmda-explorer,kave/hmda-explorer,m3brown/hmda-explorer,sleitner/hmda-explorer,m3brown/hmda-explorer,sleitner/hmda-explorer,kave/hmda-explorer
shell
## Code Before: if [ $# -ne 1 ]; then echo "usage: $0 <xlsx-filename>" exit 1 fi # https://github.com/dilshod/xlsx2csv (this gracefully handles unicode nastiness, thankfully). pip install xlsx2csv xlsx2csv -d '|' $1 tmp-msa.csv echo '<select name="hmda_chart_2_msa" id="hmda_chart_2_msa"> <option selected value="CBSA00000">U.S. Total</option>' > msa-dropdown.html awk -F "|" '{ if(NR>1){print("<option value=\"CBSA"$1"\">"$2"</option>")}}' tmp-msa.csv >> msa-dropdown.html echo '</select>' >> msa-dropdown.html echo 'successfully created msa-dropdown.html' # cleanup tmp file rm -f tmp-msa.csv ## Instruction: Remove pip install from script and make filesnames vars. ## Code After: HTMLDROPDOWN_FILE="msa-dropdown.html" if [ $# -ne 1 ]; then echo "usage: $0 <xlsx-filename>" exit 1 fi # https://github.com/dilshod/xlsx2csv (this gracefully handles unicode nastiness, thankfully). TMPCSV="tmp-msa.csv" xlsx2csv -d '|' $1 $TMPCSV 2> /dev/null || { echo >&2 "'xlsx2csv' is required for this script to execute. To install, run: pip install xlsx2csv Note that root access may be required to run pip commands. Aborting."; exit 1; } echo '<select name="hmda_chart_2_msa" id="hmda_chart_2_msa"> <option selected value="CBSA00000">U.S. Total</option>' > $HTMLDROPDOWN_FILE awk -F "|" '{ if(NR>1){print("<option value=\"CBSA"$1"\">"$2"</option>")}}' $TMPCSV >> $HTMLDROPDOWN_FILE echo '</select>' >> $HTMLDROPDOWN_FILE echo 'successfully created msa-dropdown.html' # cleanup tmp file rm -f $TMPCSV
939c5fd069fafbe353fc9a209d2bd376e8d9bbd6
gridded/gridded.py
gridded/gridded.py
class Gridded: _grid_obj_classes = [] _grids_loaded = False @classmethod def _load_grid_objs(cls): from pkg_resources import working_set for ep in working_set.iter_entry_points('gridded.grid_objects'): cls._grid_obj_classes.append(ep.load()) @classmethod def load(cls, nc, *args, **kwargs): for go in self._grid_obj_classes: if hasattr(go, 'is_mine') and go.is_mine(nc): return go(nc, *args, **kwargs)
class Gridded: _grid_obj_classes = [] _grids_loaded = False @classmethod def _load_grid_objs(cls): from pkg_resources import working_set for ep in working_set.iter_entry_points('gridded.grid_objects'): cls._grid_obj_classes.append(ep.load()) @classmethod def load(cls, *args, **kwargs): for go in cls._grid_obj_classes: if hasattr(go, 'is_mine') and go.is_mine(*args, **kwargs): return go(*args, **kwargs)
Fix self- > cls, make super generic (no `nc`)
Fix self- > cls, make super generic (no `nc`)
Python
mit
pyoceans/gridded
python
## Code Before: class Gridded: _grid_obj_classes = [] _grids_loaded = False @classmethod def _load_grid_objs(cls): from pkg_resources import working_set for ep in working_set.iter_entry_points('gridded.grid_objects'): cls._grid_obj_classes.append(ep.load()) @classmethod def load(cls, nc, *args, **kwargs): for go in self._grid_obj_classes: if hasattr(go, 'is_mine') and go.is_mine(nc): return go(nc, *args, **kwargs) ## Instruction: Fix self- > cls, make super generic (no `nc`) ## Code After: class Gridded: _grid_obj_classes = [] _grids_loaded = False @classmethod def _load_grid_objs(cls): from pkg_resources import working_set for ep in working_set.iter_entry_points('gridded.grid_objects'): cls._grid_obj_classes.append(ep.load()) @classmethod def load(cls, *args, **kwargs): for go in cls._grid_obj_classes: if hasattr(go, 'is_mine') and go.is_mine(*args, **kwargs): return go(*args, **kwargs)
8377c5eea5a99db9322ba87ae030f8f1578794c1
web/templates/page/index.html.slim
web/templates/page/index.html.slim
.columns .one-fifth.column nav.menu a.menu-item.selected href="#" span.octicon.octicon-paintcan = gettext "Styles" a.btn.btn-primary href="#{style_path(@conn, :new, @current_user.name)}" = gettext "New tweak" .four-fifths.column = if Enum.count(@styles) == 0 do .blankslate h3 = gettext "No tweaks for you to see here" - else = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn)
.columns .one-fifth.column nav.menu a.menu-item.selected href="#" span.octicon.octicon-paintcan = gettext "Styles" = if @authorized? do a.btn.btn-primary href="#{style_path(@conn, :new, @current_user.name)}" = gettext "New tweak" .four-fifths.column = if Enum.count(@styles) == 0 do .blankslate h3 = gettext "No tweaks for you to see here" - else = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn)
Add guard against not being signed in
Add guard against not being signed in
Slim
mit
lee-dohm/atom-style-tweaks,lee-dohm/atom-style-tweaks,lee-dohm/atom-style-tweaks,lee-dohm/atom-style-tweaks
slim
## Code Before: .columns .one-fifth.column nav.menu a.menu-item.selected href="#" span.octicon.octicon-paintcan = gettext "Styles" a.btn.btn-primary href="#{style_path(@conn, :new, @current_user.name)}" = gettext "New tweak" .four-fifths.column = if Enum.count(@styles) == 0 do .blankslate h3 = gettext "No tweaks for you to see here" - else = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn) ## Instruction: Add guard against not being signed in ## Code After: .columns .one-fifth.column nav.menu a.menu-item.selected href="#" span.octicon.octicon-paintcan = gettext "Styles" = if @authorized? do a.btn.btn-primary href="#{style_path(@conn, :new, @current_user.name)}" = gettext "New tweak" .four-fifths.column = if Enum.count(@styles) == 0 do .blankslate h3 = gettext "No tweaks for you to see here" - else = render_many(@styles, AtomStyleTweaks.StyleView, "table_row.html", conn: @conn)
f5fff2124d6ff3bb96e7359f928e61614577a072
test/fixture/package/src/Guess/Return.js
test/fixture/package/src/Guess/Return.js
/** * this is TestGuessReturn. */ export default class TestGuessReturn { method1(){ return 123; } method2(){ return [123, 456]; } method3(){ return {x1: 123, x2: 'text'}; } method4(){ return `text`; } }
/** * this is TestGuessReturn. */ export default class TestGuessReturn { method1(){ return 123; } method2(){ return [123, 456]; } method3(){ return {x1: 123, x2: 'text'}; } method4(){ return `text`; } method5(){ const obj = {} return {...obj} } }
Add test to show parser crash.
Add test to show parser crash.
JavaScript
mit
esdoc/esdoc,h13i32maru/esdoc,h13i32maru/esdoc
javascript
## Code Before: /** * this is TestGuessReturn. */ export default class TestGuessReturn { method1(){ return 123; } method2(){ return [123, 456]; } method3(){ return {x1: 123, x2: 'text'}; } method4(){ return `text`; } } ## Instruction: Add test to show parser crash. ## Code After: /** * this is TestGuessReturn. */ export default class TestGuessReturn { method1(){ return 123; } method2(){ return [123, 456]; } method3(){ return {x1: 123, x2: 'text'}; } method4(){ return `text`; } method5(){ const obj = {} return {...obj} } }
04be30d701e8de81cf644489a07e578e130bee72
README.md
README.md
A simple mongoose plugin to provide private Schema keys ## Getting Started Install the module with: `npm install mongoose-private-paths` ## Documentation _(Coming soon)_ ## Examples _(Coming soon)_ ## Contributing Just lint and test using [Grunt](http://gruntjs.com/). ## License Copyright (c) 2013 . Licensed under the MIT license.
A simple mongoose plugin to provide private Schema keys ## Getting Started Install the module with: `npm install mongoose-private-paths` ```javascript var mongoose = require('mongoose'), privatePaths = require('mongoose-private-paths'); var TestSchema = new mongoose.Schema({ public: { type: String }, _private: { type: String }, also_private: { type: String, private: true }, not_private: { type: String, private: false } }); TestSchema.plugin(privatePaths); var Test = mongoose.model('Test', Testschema); var test = new Test({ public: 'all keys are public by default!', _private: 'keys prefixed with an "_" will be private - except "_id"', also_private: 'stuff with a "private" field set to true will be... private!', not_private: 'stuff with a "private" field set to false will be... NOT private!', _even: 'if they are prefixed with an "_"' }); test.toJSON(); // => // { // public: 'all keys are public by default!', // _not_private: 'stuff with a "private" field set to false will be... NOT private!', // _even: 'if they are prefixed with an "_"' // } ``` ## Documentation _(Coming soon)_ ## Examples _(Coming soon)_ ## Contributing Just lint and test using [Grunt](http://gruntjs.com/). ## License Copyright (c) 2013 . Licensed under the MIT license.
Add a basic usage example
Add a basic usage example
Markdown
mit
yamadapc/mongoose-private-paths
markdown
## Code Before: A simple mongoose plugin to provide private Schema keys ## Getting Started Install the module with: `npm install mongoose-private-paths` ## Documentation _(Coming soon)_ ## Examples _(Coming soon)_ ## Contributing Just lint and test using [Grunt](http://gruntjs.com/). ## License Copyright (c) 2013 . Licensed under the MIT license. ## Instruction: Add a basic usage example ## Code After: A simple mongoose plugin to provide private Schema keys ## Getting Started Install the module with: `npm install mongoose-private-paths` ```javascript var mongoose = require('mongoose'), privatePaths = require('mongoose-private-paths'); var TestSchema = new mongoose.Schema({ public: { type: String }, _private: { type: String }, also_private: { type: String, private: true }, not_private: { type: String, private: false } }); TestSchema.plugin(privatePaths); var Test = mongoose.model('Test', Testschema); var test = new Test({ public: 'all keys are public by default!', _private: 'keys prefixed with an "_" will be private - except "_id"', also_private: 'stuff with a "private" field set to true will be... private!', not_private: 'stuff with a "private" field set to false will be... NOT private!', _even: 'if they are prefixed with an "_"' }); test.toJSON(); // => // { // public: 'all keys are public by default!', // _not_private: 'stuff with a "private" field set to false will be... NOT private!', // _even: 'if they are prefixed with an "_"' // } ``` ## Documentation _(Coming soon)_ ## Examples _(Coming soon)_ ## Contributing Just lint and test using [Grunt](http://gruntjs.com/). ## License Copyright (c) 2013 . Licensed under the MIT license.
f6aa224d82081fe78593cc6f4fee113572843178
.travis.yml
.travis.yml
language: rust rust: - nightly-2018-04-01
language: rust rust: - nightly-2018-04-01 cache: cargo sudo: required dist: trusty
Add caching to Travis config
Add caching to Travis config
YAML
mit
pombase/pombase-chado-json,pombase/pombase-chado-json
yaml
## Code Before: language: rust rust: - nightly-2018-04-01 ## Instruction: Add caching to Travis config ## Code After: language: rust rust: - nightly-2018-04-01 cache: cargo sudo: required dist: trusty
b87e2d6f0a59068e15694a8eea6c00580528cdb2
sellers/templates/sellers/accept.html
sellers/templates/sellers/accept.html
{% extends "common/base.html" %} {% load i18n %} {% load manage_header %} {% block title %}{% trans "Sellers with unaccepted books - Accept books" %}{% endblock %} {% block content %} <h1>{% trans "Sellers with unaccepted books" %} <small>{% blocktrans %}Accept {{ user_name }}'s books{% endblocktrans %}</small> </h1> {% manage_header "sellers/accept_books" %} <div class="alert alert-info">{% trans "If you want to delete some book, just pass 0 as amount." %}</div> <form action="{{ request.path }}" method="post"> {% csrf_token %} {% include 'sellers/accept_book_list.html' with show_actions=True%} <a href="{% url 'sellers.views.index' %}" class="btn btn-default" role="button"><span class="glyphicon glyphicon-remove"></span> {% trans "Cancel" %}</a> <button class="btn btn-primary pull-right" role="submit"><span class="glyphicon glyphicon-ok"></span> {% trans "Accept" %}</button> </form> {% endblock %}
{% extends "common/base.html" %} {% load i18n %} {% load manage_header %} {% block title %}{% trans "Sellers with unaccepted books - Accept books" %}{% endblock %} {% block head %} <style> .input-group-addon, .input-group-btn { width: auto; } </style> {% endblock %} {% block content %} <h1>{% trans "Sellers with unaccepted books" %} <small>{% blocktrans %}Accept {{ user_name }}'s books{% endblocktrans %}</small> </h1> {% manage_header "sellers/accept_books" %} <div class="alert alert-info">{% trans "If you want to delete some book, just pass 0 as amount." %}</div> <form action="{{ request.path }}" method="post"> {% csrf_token %} {% include 'sellers/accept_book_list.html' with show_actions=True%} <a href="{% url 'sellers.views.index' %}" class="btn btn-default" role="button"><span class="glyphicon glyphicon-remove"></span> {% trans "Cancel" %}</a> <button class="btn btn-primary pull-right" role="submit"><span class="glyphicon glyphicon-ok"></span> {% trans "Accept" %}</button> </form> {% endblock %}
Fix addon field displaying in browsers with WebKit
Fix addon field displaying in browsers with WebKit
HTML
agpl-3.0
m4tx/egielda,m4tx/egielda,m4tx/egielda
html
## Code Before: {% extends "common/base.html" %} {% load i18n %} {% load manage_header %} {% block title %}{% trans "Sellers with unaccepted books - Accept books" %}{% endblock %} {% block content %} <h1>{% trans "Sellers with unaccepted books" %} <small>{% blocktrans %}Accept {{ user_name }}'s books{% endblocktrans %}</small> </h1> {% manage_header "sellers/accept_books" %} <div class="alert alert-info">{% trans "If you want to delete some book, just pass 0 as amount." %}</div> <form action="{{ request.path }}" method="post"> {% csrf_token %} {% include 'sellers/accept_book_list.html' with show_actions=True%} <a href="{% url 'sellers.views.index' %}" class="btn btn-default" role="button"><span class="glyphicon glyphicon-remove"></span> {% trans "Cancel" %}</a> <button class="btn btn-primary pull-right" role="submit"><span class="glyphicon glyphicon-ok"></span> {% trans "Accept" %}</button> </form> {% endblock %} ## Instruction: Fix addon field displaying in browsers with WebKit ## Code After: {% extends "common/base.html" %} {% load i18n %} {% load manage_header %} {% block title %}{% trans "Sellers with unaccepted books - Accept books" %}{% endblock %} {% block head %} <style> .input-group-addon, .input-group-btn { width: auto; } </style> {% endblock %} {% block content %} <h1>{% trans "Sellers with unaccepted books" %} <small>{% blocktrans %}Accept {{ user_name }}'s books{% endblocktrans %}</small> </h1> {% manage_header "sellers/accept_books" %} <div class="alert alert-info">{% trans "If you want to delete some book, just pass 0 as amount." %}</div> <form action="{{ request.path }}" method="post"> {% csrf_token %} {% include 'sellers/accept_book_list.html' with show_actions=True%} <a href="{% url 'sellers.views.index' %}" class="btn btn-default" role="button"><span class="glyphicon glyphicon-remove"></span> {% trans "Cancel" %}</a> <button class="btn btn-primary pull-right" role="submit"><span class="glyphicon glyphicon-ok"></span> {% trans "Accept" %}</button> </form> {% endblock %}
27737aa3a9f65012b3656b71e0ff230a4811da4d
include/net/dcbevent.h
include/net/dcbevent.h
/* * Copyright (c) 2010, Intel Corporation. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, * version 2, as published by the Free Software Foundation. * * This program is distributed in the hope it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for * more details. * * You should have received a copy of the GNU General Public License along with * this program; if not, write to the Free Software Foundation, Inc., 59 Temple * Place - Suite 330, Boston, MA 02111-1307 USA. * * Author: John Fastabend <[email protected]> */ #ifndef _DCB_EVENT_H #define _DCB_EVENT_H enum dcbevent_notif_type { DCB_APP_EVENT = 1, }; extern int register_dcbevent_notifier(struct notifier_block *nb); extern int unregister_dcbevent_notifier(struct notifier_block *nb); extern int call_dcbevent_notifiers(unsigned long val, void *v); #endif
/* * Copyright (c) 2010, Intel Corporation. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, * version 2, as published by the Free Software Foundation. * * This program is distributed in the hope it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for * more details. * * You should have received a copy of the GNU General Public License along with * this program; if not, write to the Free Software Foundation, Inc., 59 Temple * Place - Suite 330, Boston, MA 02111-1307 USA. * * Author: John Fastabend <[email protected]> */ #ifndef _DCB_EVENT_H #define _DCB_EVENT_H enum dcbevent_notif_type { DCB_APP_EVENT = 1, }; #ifdef CONFIG_DCB extern int register_dcbevent_notifier(struct notifier_block *nb); extern int unregister_dcbevent_notifier(struct notifier_block *nb); extern int call_dcbevent_notifiers(unsigned long val, void *v); #else static inline int register_dcbevent_notifier(struct notifier_block *nb) { return 0; } static inline int unregister_dcbevent_notifier(struct notifier_block *nb) { return 0; } static inline int call_dcbevent_notifiers(unsigned long val, void *v) { return 0; } #endif /* CONFIG_DCB */ #endif
Add stub routines for !CONFIG_DCB
dcb: Add stub routines for !CONFIG_DCB To avoid ifdefs in the other code that supports DCB notifiers add stub routines. This method seems popular in other net code for example 8021Q. Signed-off-by: John Fastabend <[email protected]> Signed-off-by: David S. Miller <[email protected]>
C
mit
KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,TeamVee-Kanas/android_kernel_samsung_kanas,KristFoundation/Programs
c
## Code Before: /* * Copyright (c) 2010, Intel Corporation. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, * version 2, as published by the Free Software Foundation. * * This program is distributed in the hope it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for * more details. * * You should have received a copy of the GNU General Public License along with * this program; if not, write to the Free Software Foundation, Inc., 59 Temple * Place - Suite 330, Boston, MA 02111-1307 USA. * * Author: John Fastabend <[email protected]> */ #ifndef _DCB_EVENT_H #define _DCB_EVENT_H enum dcbevent_notif_type { DCB_APP_EVENT = 1, }; extern int register_dcbevent_notifier(struct notifier_block *nb); extern int unregister_dcbevent_notifier(struct notifier_block *nb); extern int call_dcbevent_notifiers(unsigned long val, void *v); #endif ## Instruction: dcb: Add stub routines for !CONFIG_DCB To avoid ifdefs in the other code that supports DCB notifiers add stub routines. This method seems popular in other net code for example 8021Q. Signed-off-by: John Fastabend <[email protected]> Signed-off-by: David S. Miller <[email protected]> ## Code After: /* * Copyright (c) 2010, Intel Corporation. * * This program is free software; you can redistribute it and/or modify it * under the terms and conditions of the GNU General Public License, * version 2, as published by the Free Software Foundation. * * This program is distributed in the hope it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for * more details. * * You should have received a copy of the GNU General Public License along with * this program; if not, write to the Free Software Foundation, Inc., 59 Temple * Place - Suite 330, Boston, MA 02111-1307 USA. * * Author: John Fastabend <[email protected]> */ #ifndef _DCB_EVENT_H #define _DCB_EVENT_H enum dcbevent_notif_type { DCB_APP_EVENT = 1, }; #ifdef CONFIG_DCB extern int register_dcbevent_notifier(struct notifier_block *nb); extern int unregister_dcbevent_notifier(struct notifier_block *nb); extern int call_dcbevent_notifiers(unsigned long val, void *v); #else static inline int register_dcbevent_notifier(struct notifier_block *nb) { return 0; } static inline int unregister_dcbevent_notifier(struct notifier_block *nb) { return 0; } static inline int call_dcbevent_notifiers(unsigned long val, void *v) { return 0; } #endif /* CONFIG_DCB */ #endif
b5b0362e9a2fa9b9b5a5c916b390e7bc184eb8fc
README.md
README.md
Exercism exercises in C# ## Contributing Guide Please see the [contributing guide](https://github.com/exercism/x-api/blob/master/CONTRIBUTING.md#the-exercise-data) ## License The MIT License (MIT) Copyright (c) 2014 Katrina Owen, [email protected]
[![Build Status](https://travis-ci.org/exercism/xcsharp.svg?branch=master)](https://travis-ci.org/exercism/xcsharp) [![Build status](https://ci.appveyor.com/api/projects/status/r7o9t6gjoc09jpmn/branch/master?svg=true)](https://ci.appveyor.com/project/ErikSchierboom/xcsharp-c03a2/branch/master) Exercism exercises in C# ## Contributing Guide Please see the [contributing guide](https://github.com/exercism/x-api/blob/master/CONTRIBUTING.md#the-exercise-data) ## License The MIT License (MIT) Copyright (c) 2014 Katrina Owen, [email protected]
Add AppVeyor and Travis badge
Add AppVeyor and Travis badge
Markdown
mit
exercism/xcsharp,exercism/xcsharp,GKotfis/csharp,ErikSchierboom/xcsharp,ErikSchierboom/xcsharp,robkeim/xcsharp,robkeim/xcsharp,GKotfis/csharp
markdown
## Code Before: Exercism exercises in C# ## Contributing Guide Please see the [contributing guide](https://github.com/exercism/x-api/blob/master/CONTRIBUTING.md#the-exercise-data) ## License The MIT License (MIT) Copyright (c) 2014 Katrina Owen, [email protected] ## Instruction: Add AppVeyor and Travis badge ## Code After: [![Build Status](https://travis-ci.org/exercism/xcsharp.svg?branch=master)](https://travis-ci.org/exercism/xcsharp) [![Build status](https://ci.appveyor.com/api/projects/status/r7o9t6gjoc09jpmn/branch/master?svg=true)](https://ci.appveyor.com/project/ErikSchierboom/xcsharp-c03a2/branch/master) Exercism exercises in C# ## Contributing Guide Please see the [contributing guide](https://github.com/exercism/x-api/blob/master/CONTRIBUTING.md#the-exercise-data) ## License The MIT License (MIT) Copyright (c) 2014 Katrina Owen, [email protected]
7c8f4820e1c55ab26a2623e9644d01d5af4bc6dc
lib/config/hisilicon/env.sh
lib/config/hisilicon/env.sh
jagen_overlays='ast/board/ast2xx toolchain/arm-hisiv200-linux sdk/android ast/common product/android ast/product/hisilicon' jagen_toolchain_dir='$jagen_base_dir/toolchain/arm-hisiv200-linux' jagen_sdk_dir='$jagen_src_dir/hisilicon'
jagen_overlays='ast/board/ast2xx toolchain/arm-hisiv200-linux sdk/android product/android ast/common ast/product/hisilicon' jagen_toolchain_dir='$jagen_base_dir/toolchain/arm-hisiv200-linux' jagen_sdk_dir='$jagen_src_dir/hisilicon'
Change overlay order in hisilicon config for consistency
Change overlay order in hisilicon config for consistency
Shell
mit
bazurbat/jagen
shell
## Code Before: jagen_overlays='ast/board/ast2xx toolchain/arm-hisiv200-linux sdk/android ast/common product/android ast/product/hisilicon' jagen_toolchain_dir='$jagen_base_dir/toolchain/arm-hisiv200-linux' jagen_sdk_dir='$jagen_src_dir/hisilicon' ## Instruction: Change overlay order in hisilicon config for consistency ## Code After: jagen_overlays='ast/board/ast2xx toolchain/arm-hisiv200-linux sdk/android product/android ast/common ast/product/hisilicon' jagen_toolchain_dir='$jagen_base_dir/toolchain/arm-hisiv200-linux' jagen_sdk_dir='$jagen_src_dir/hisilicon'
7582079119b15b7d5feeb6ebda543646b0de8d6a
tools/powershell/Turbo/Set-JsonPreference.ps1
tools/powershell/Turbo/Set-JsonPreference.ps1
function Set-JsonPreference { [CmdletBinding()] param ( [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Path, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Category, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Property, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [AllowEmptyString()] [string] $Value ) process { $json = (Get-Content $Path) | ConvertFrom-Json $categoryValue = $json.PSobject.Properties | Where-Object {$_.Name -eq $Category} if($categoryValue) { Add-Member -Name $Property -Value $Value -MemberType NoteProperty -InputObject $json.$Category -Force } else { $json | Add-Member -Name $category -Value @{ $Property = $Value } -MemberType NoteProperty } ConvertTo-Json $json -Compress | Set-Content $Path return $true } }
function Set-JsonPreference { [CmdletBinding()] param ( [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Path, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Category, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Property, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [AllowEmptyString()] # Skipped type declaration to avoid unwanted conversions (example: $true should be a boolean, not a string value - "true") $Value ) process { $json = (Get-Content $Path) | ConvertFrom-Json $categoryValue = $json.PSobject.Properties | Where-Object {$_.Name -eq $Category} if($categoryValue) { Add-Member -Name $Property -Value $Value -MemberType NoteProperty -InputObject $json.$Category -Force } else { $json | Add-Member -Name $category -Value @{ $Property = $Value } -MemberType NoteProperty } ConvertTo-Json $json -Compress | Set-Content $Path return $true } }
Remove Cmdlet type declaration - caused implicit conversions to string
Remove Cmdlet type declaration - caused implicit conversions to string
PowerShell
apache-2.0
turboapps/turbome,turboapps/turbome,turboapps/turbome
powershell
## Code Before: function Set-JsonPreference { [CmdletBinding()] param ( [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Path, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Category, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Property, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [AllowEmptyString()] [string] $Value ) process { $json = (Get-Content $Path) | ConvertFrom-Json $categoryValue = $json.PSobject.Properties | Where-Object {$_.Name -eq $Category} if($categoryValue) { Add-Member -Name $Property -Value $Value -MemberType NoteProperty -InputObject $json.$Category -Force } else { $json | Add-Member -Name $category -Value @{ $Property = $Value } -MemberType NoteProperty } ConvertTo-Json $json -Compress | Set-Content $Path return $true } } ## Instruction: Remove Cmdlet type declaration - caused implicit conversions to string ## Code After: function Set-JsonPreference { [CmdletBinding()] param ( [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Path, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Category, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [string] $Property, [Parameter(Mandatory=$True,ValueFromPipeline=$True,ValueFromPipelineByPropertyName=$True)] [AllowEmptyString()] # Skipped type declaration to avoid unwanted conversions (example: $true should be a boolean, not a string value - "true") $Value ) process { $json = (Get-Content $Path) | ConvertFrom-Json $categoryValue = $json.PSobject.Properties | Where-Object {$_.Name -eq $Category} if($categoryValue) { Add-Member -Name $Property -Value $Value -MemberType NoteProperty -InputObject $json.$Category -Force } else { $json | Add-Member -Name $category -Value @{ $Property = $Value } -MemberType NoteProperty } ConvertTo-Json $json -Compress | Set-Content $Path return $true } }
381bc282f8f842cc8d4ab344cae6564056a8db1e
compiler_source/6_actions_perl/template-runtime-code-for-action-copy-characters-from-position-to-position.txt
compiler_source/6_actions_perl/template-runtime-code-for-action-copy-characters-from-position-to-position.txt
template-runtime-code-standard-action-begin $global_character_pointer_begin = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-three ) ; <new_line> $global_character_pointer_end = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-four ) ; <new_line> code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-two code-get-or-put-phrase-definition-end = substr( code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-one code-get-or-put-phrase-definition-end , $global_character_pointer_begin - 1 , $global_character_pointer_end - $global_character_pointer_begin + 1 ) ; <new_line> runtime-code-storage-item-result = '' ; <new_line> template-runtime-code-standard-action-end
template-runtime-code-standard-action-begin $global_character_pointer_begin = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-three ) ; <new_line> $global_character_pointer_end = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-four ) ; <new_line> if ( $global_character_pointer_begin > $global_character_pointer_end ) { <new_line> $global_character_pointer_saved = $global_character_pointer_begin ; <new_line> $global_character_pointer_begin = $global_character_pointer_end ; <new_line> $global_character_pointer_end = $global_character_pointer_saved ; <new_line> } <new_line> code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-two code-get-or-put-phrase-definition-end = substr( code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-one code-get-or-put-phrase-definition-end , $global_character_pointer_begin - 1 , $global_character_pointer_end - $global_character_pointer_begin + 1 ) ; <new_line> runtime-code-storage-item-result = '' ; <new_line> template-runtime-code-standard-action-end
Swap starting and ending character pointers if needed
Swap starting and ending character pointers if needed
Text
artistic-2.0
cpsolver/Dashrep-language,cpsolver/Dashrep-language,cpsolver/Dashrep-language
text
## Code Before: template-runtime-code-standard-action-begin $global_character_pointer_begin = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-three ) ; <new_line> $global_character_pointer_end = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-four ) ; <new_line> code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-two code-get-or-put-phrase-definition-end = substr( code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-one code-get-or-put-phrase-definition-end , $global_character_pointer_begin - 1 , $global_character_pointer_end - $global_character_pointer_begin + 1 ) ; <new_line> runtime-code-storage-item-result = '' ; <new_line> template-runtime-code-standard-action-end ## Instruction: Swap starting and ending character pointers if needed ## Code After: template-runtime-code-standard-action-begin $global_character_pointer_begin = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-three ) ; <new_line> $global_character_pointer_end = &function_parameterized__convert_numeric_text_into_numeric_value( runtime-code-for-operand-number-four ) ; <new_line> if ( $global_character_pointer_begin > $global_character_pointer_end ) { <new_line> $global_character_pointer_saved = $global_character_pointer_begin ; <new_line> $global_character_pointer_begin = $global_character_pointer_end ; <new_line> $global_character_pointer_end = $global_character_pointer_saved ; <new_line> } <new_line> code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-two code-get-or-put-phrase-definition-end = substr( code-get-or-put-phrase-definition-begin runtime-code-for-operand-number-one code-get-or-put-phrase-definition-end , $global_character_pointer_begin - 1 , $global_character_pointer_end - $global_character_pointer_begin + 1 ) ; <new_line> runtime-code-storage-item-result = '' ; <new_line> template-runtime-code-standard-action-end
57a67d06f157dd2dbea0463309da741ad35283ed
spec/spec_helper.rb
spec/spec_helper.rb
ENV['RAILS_ENV'] = 'test' ENGINE_RAILS_ROOT = File.join(File.dirname(__FILE__), '../') if ENV['CODECLIMATE_REPO_TOKEN'] require "codeclimate-test-reporter" CodeClimate::TestReporter.start end require File.expand_path('../dummy/config/environment.rb', __FILE__) ActiveRecord::Migrator.migrations_paths = [File.expand_path('../../test/dummy/db/migrate', __FILE__)] ActiveRecord::Migrator.migrations_paths << File.expand_path('../../db/migrate', __FILE__) require 'vcr' require 'rspec/rails' ActiveRecord::Migration.maintain_test_schema! RSpec.configure do |c| c.expect_with :rspec do |expectations| expectations.include_chain_clauses_in_custom_matcher_descriptions = true end c.use_transactional_fixtures = true c.filter_run :focus c.run_all_when_everything_filtered = true c.disable_monkey_patching! c.warnings = true c.default_formatter = 'doc' if c.files_to_run.one? c.order = :random Kernel.srand c.seed end VCR.configure do |c| c.cassette_library_dir = 'spec/fixtures/vcr_cassettes' c.hook_into :webmock c.configure_rspec_metadata! end
ENV['RAILS_ENV'] = 'test' ENGINE_RAILS_ROOT = File.join(File.dirname(__FILE__), '../') if ENV['CODECLIMATE_REPO_TOKEN'] require 'codeclimate-test-reporter' CodeClimate::TestReporter.start end require File.expand_path('../dummy/config/environment.rb', __FILE__) ActiveRecord::Migrator.migrations_paths = [File.expand_path('../../test/dummy/db/migrate', __FILE__)] ActiveRecord::Migrator.migrations_paths << File.expand_path('../../db/migrate', __FILE__) require 'vcr' require 'rspec/rails' ActiveRecord::Migration.maintain_test_schema! RSpec.configure do |c| c.expect_with :rspec do |expectations| expectations.include_chain_clauses_in_custom_matcher_descriptions = true end c.use_transactional_fixtures = true c.filter_run :focus c.run_all_when_everything_filtered = true c.disable_monkey_patching! c.warnings = true c.default_formatter = 'doc' if c.files_to_run.one? c.order = :random Kernel.srand c.seed end VCR.configure do |c| c.cassette_library_dir = 'spec/fixtures/vcr_cassettes' c.hook_into :webmock c.configure_rspec_metadata! c.ignore_hosts 'codeclimate.com' end
Allow VCR to post to codeclimate
Allow VCR to post to codeclimate
Ruby
mit
brightin/recoil,brightin/recoil,brightin/recoil
ruby
## Code Before: ENV['RAILS_ENV'] = 'test' ENGINE_RAILS_ROOT = File.join(File.dirname(__FILE__), '../') if ENV['CODECLIMATE_REPO_TOKEN'] require "codeclimate-test-reporter" CodeClimate::TestReporter.start end require File.expand_path('../dummy/config/environment.rb', __FILE__) ActiveRecord::Migrator.migrations_paths = [File.expand_path('../../test/dummy/db/migrate', __FILE__)] ActiveRecord::Migrator.migrations_paths << File.expand_path('../../db/migrate', __FILE__) require 'vcr' require 'rspec/rails' ActiveRecord::Migration.maintain_test_schema! RSpec.configure do |c| c.expect_with :rspec do |expectations| expectations.include_chain_clauses_in_custom_matcher_descriptions = true end c.use_transactional_fixtures = true c.filter_run :focus c.run_all_when_everything_filtered = true c.disable_monkey_patching! c.warnings = true c.default_formatter = 'doc' if c.files_to_run.one? c.order = :random Kernel.srand c.seed end VCR.configure do |c| c.cassette_library_dir = 'spec/fixtures/vcr_cassettes' c.hook_into :webmock c.configure_rspec_metadata! end ## Instruction: Allow VCR to post to codeclimate ## Code After: ENV['RAILS_ENV'] = 'test' ENGINE_RAILS_ROOT = File.join(File.dirname(__FILE__), '../') if ENV['CODECLIMATE_REPO_TOKEN'] require 'codeclimate-test-reporter' CodeClimate::TestReporter.start end require File.expand_path('../dummy/config/environment.rb', __FILE__) ActiveRecord::Migrator.migrations_paths = [File.expand_path('../../test/dummy/db/migrate', __FILE__)] ActiveRecord::Migrator.migrations_paths << File.expand_path('../../db/migrate', __FILE__) require 'vcr' require 'rspec/rails' ActiveRecord::Migration.maintain_test_schema! RSpec.configure do |c| c.expect_with :rspec do |expectations| expectations.include_chain_clauses_in_custom_matcher_descriptions = true end c.use_transactional_fixtures = true c.filter_run :focus c.run_all_when_everything_filtered = true c.disable_monkey_patching! c.warnings = true c.default_formatter = 'doc' if c.files_to_run.one? c.order = :random Kernel.srand c.seed end VCR.configure do |c| c.cassette_library_dir = 'spec/fixtures/vcr_cassettes' c.hook_into :webmock c.configure_rspec_metadata! c.ignore_hosts 'codeclimate.com' end
0a4885ef62789616164faf6d7ca35e91109a46d8
examples/parser/webpack/test/webpack_spec.js
examples/parser/webpack/test/webpack_spec.js
const { expect } = require("chai") describe("Chevrotain Webpacking support", () => { it("Can be webpacked without any special configuration when the grammar and tokens are defined in the same file", () => { const parse = require("../lib/webpacked.min").parse const parseResult = parse("[1,2,3]") expect(parseResult.errors).to.be.empty }) })
const { expect } = require("chai") const { lt } = require("semver") // not sure why this fails on nodejs 6 nor do I believe it is relevant to the example. let itButSkipOnNode6 = lt(process.version, "8.0.0") ? it.skip : it describe("Chevrotain Webpacking support", () => { itButSkipOnNode6( "Can be webpacked by configuring reserved words for name mangling", () => { const parse = require("../lib/webpacked.min").parse const parseResult = parse("[1,2,3]") expect(parseResult.errors).to.be.empty } ) })
Fix failing build under node.js 6
Fix failing build under node.js 6
JavaScript
apache-2.0
SAP/chevrotain,SAP/chevrotain,SAP/chevrotain,SAP/chevrotain
javascript
## Code Before: const { expect } = require("chai") describe("Chevrotain Webpacking support", () => { it("Can be webpacked without any special configuration when the grammar and tokens are defined in the same file", () => { const parse = require("../lib/webpacked.min").parse const parseResult = parse("[1,2,3]") expect(parseResult.errors).to.be.empty }) }) ## Instruction: Fix failing build under node.js 6 ## Code After: const { expect } = require("chai") const { lt } = require("semver") // not sure why this fails on nodejs 6 nor do I believe it is relevant to the example. let itButSkipOnNode6 = lt(process.version, "8.0.0") ? it.skip : it describe("Chevrotain Webpacking support", () => { itButSkipOnNode6( "Can be webpacked by configuring reserved words for name mangling", () => { const parse = require("../lib/webpacked.min").parse const parseResult = parse("[1,2,3]") expect(parseResult.errors).to.be.empty } ) })
01e58db8608f992a8e29265cc7ed13d8b191ea8e
src/redux/urlQueryMiddleware.js
src/redux/urlQueryMiddleware.js
import urlQueryReducer from './urlQueryReducer'; import urlQueryConfig from '../urlQueryConfig'; /** * Middleware to handle updating the URL query params */ const urlQueryMiddleware = (options = {}) => ({ getState }) => next => (action) => { // if not a URL action, do nothing. if (!action.meta || !action.meta.urlQuery) { return next(action); } // otherwise, handle with URL handler -- doesn't go to Redux dispatcher // update the URL // use the default reducer if none provided const reducer = options.reducer || urlQueryConfig.reducer || urlQueryReducer; // if configured to read from the redux store (react-router-redux), do so and pass it to // the reducer const readLocationFromStore = options.readLocationFromStore == null ? urlQueryConfig.readLocationFromStore : options.readLocationFromStore; if (readLocationFromStore) { const location = readLocationFromStore(getState()); return reducer(action, location); } return reducer(action); }; export default urlQueryMiddleware;
import urlQueryReducer from './urlQueryReducer'; import urlQueryConfig from '../urlQueryConfig'; /** * Middleware to handle updating the URL query params */ const urlQueryMiddleware = (options = {}) => ({ getState }) => next => (action) => { // if not a URL action, do nothing. if (!action.meta || !action.meta.urlQuery) { return next(action); } // otherwise, handle with URL handler -- doesn't go to Redux dispatcher // update the URL // use the default reducer if none provided const reducer = options.reducer || urlQueryConfig.reducer || urlQueryReducer; // if configured to read from the redux store (react-router-redux), do so and pass it to // the reducer const readLocationFromStore = options.readLocationFromStore == null ? urlQueryConfig.readLocationFromStore : options.readLocationFromStore; if (readLocationFromStore) { const location = readLocationFromStore(getState()); reducer(action, location); } else { reducer(action); } // shortcircuit by default (don't pass to redux store), unless explicitly set // to false. if (options.shortcircuit === false) { return next(action); } return undefined; }; export default urlQueryMiddleware;
Make short-circuiting redux store optional
Make short-circuiting redux store optional
JavaScript
mit
pbeshai/react-url-query
javascript
## Code Before: import urlQueryReducer from './urlQueryReducer'; import urlQueryConfig from '../urlQueryConfig'; /** * Middleware to handle updating the URL query params */ const urlQueryMiddleware = (options = {}) => ({ getState }) => next => (action) => { // if not a URL action, do nothing. if (!action.meta || !action.meta.urlQuery) { return next(action); } // otherwise, handle with URL handler -- doesn't go to Redux dispatcher // update the URL // use the default reducer if none provided const reducer = options.reducer || urlQueryConfig.reducer || urlQueryReducer; // if configured to read from the redux store (react-router-redux), do so and pass it to // the reducer const readLocationFromStore = options.readLocationFromStore == null ? urlQueryConfig.readLocationFromStore : options.readLocationFromStore; if (readLocationFromStore) { const location = readLocationFromStore(getState()); return reducer(action, location); } return reducer(action); }; export default urlQueryMiddleware; ## Instruction: Make short-circuiting redux store optional ## Code After: import urlQueryReducer from './urlQueryReducer'; import urlQueryConfig from '../urlQueryConfig'; /** * Middleware to handle updating the URL query params */ const urlQueryMiddleware = (options = {}) => ({ getState }) => next => (action) => { // if not a URL action, do nothing. if (!action.meta || !action.meta.urlQuery) { return next(action); } // otherwise, handle with URL handler -- doesn't go to Redux dispatcher // update the URL // use the default reducer if none provided const reducer = options.reducer || urlQueryConfig.reducer || urlQueryReducer; // if configured to read from the redux store (react-router-redux), do so and pass it to // the reducer const readLocationFromStore = options.readLocationFromStore == null ? urlQueryConfig.readLocationFromStore : options.readLocationFromStore; if (readLocationFromStore) { const location = readLocationFromStore(getState()); reducer(action, location); } else { reducer(action); } // shortcircuit by default (don't pass to redux store), unless explicitly set // to false. if (options.shortcircuit === false) { return next(action); } return undefined; }; export default urlQueryMiddleware;
50041233658459ff5805276309e8ed2ee478407e
docs/source/reference/routines.rst
docs/source/reference/routines.rst
-------- Routines -------- The following pages describe NumPy-compatible routines. These functions cover a subset of `NumPy routines <https://docs.scipy.org/doc/numpy/reference/routines.html>`_. .. currentmodule:: cupy .. toctree:: :maxdepth: 2 creation manipulation binary dtype fft functional indexing io linalg logic math pad polynomials random sorting statistics ext CUB backend for reduction routines ---------------------------------- Some CuPy reduction routines, including :func:`~cupy.sum`, :func:`~cupy.min`, :func:`~cupy.max`, :func:`~cupy.argmin`, :func:`~cupy.argmax`, and other functions built on top of them, can be accelerated by switching to the `CUB`_ backend. The switch can be toggled on or off at runtime by setting the bool :data:`cupy.cuda.cub_enabled`, which is set to ``False`` by default. Note that while in general CUB-backed reductions are faster, there could be exceptions depending on the data layout. We recommend users to perform some benchmarks to determine whether CUB offers better performance or not. .. _CUB: http://nvlabs.github.io/cub/
-------- Routines -------- The following pages describe NumPy-compatible routines. These functions cover a subset of `NumPy routines <https://docs.scipy.org/doc/numpy/reference/routines.html>`_. .. currentmodule:: cupy .. toctree:: :maxdepth: 2 creation manipulation binary dtype fft functional indexing io linalg logic math pad polynomials random sorting statistics ext CUB/cuTENSOR backend for reduction routines ---------------------------------- Some CuPy reduction routines, including :func:`~cupy.sum`, :func:`~cupy.min`, :func:`~cupy.max`, :func:`~cupy.argmin`, :func:`~cupy.argmax`, and other functions built on top of them, can be accelerated by switching to the `CUB`_ or `cuTENSOR`_ backend. These backends can be enabled by setting ``CUPY_ACCELERATORS`` environement variable. Note that while in general the accelerated reductions are faster, there could be exceptions depending on the data layout. We recommend users to perform some benchmarks to determine whether CUB offers better performance or not. .. _CUB: https://nvlabs.github.io/cub/ .. _cuTENSOR: https://docs.nvidia.com/cuda/cutensor/index.html
Fix documents to reflect CUPY_ACCELERATORS
Fix documents to reflect CUPY_ACCELERATORS
reStructuredText
mit
cupy/cupy,cupy/cupy,cupy/cupy,cupy/cupy
restructuredtext
## Code Before: -------- Routines -------- The following pages describe NumPy-compatible routines. These functions cover a subset of `NumPy routines <https://docs.scipy.org/doc/numpy/reference/routines.html>`_. .. currentmodule:: cupy .. toctree:: :maxdepth: 2 creation manipulation binary dtype fft functional indexing io linalg logic math pad polynomials random sorting statistics ext CUB backend for reduction routines ---------------------------------- Some CuPy reduction routines, including :func:`~cupy.sum`, :func:`~cupy.min`, :func:`~cupy.max`, :func:`~cupy.argmin`, :func:`~cupy.argmax`, and other functions built on top of them, can be accelerated by switching to the `CUB`_ backend. The switch can be toggled on or off at runtime by setting the bool :data:`cupy.cuda.cub_enabled`, which is set to ``False`` by default. Note that while in general CUB-backed reductions are faster, there could be exceptions depending on the data layout. We recommend users to perform some benchmarks to determine whether CUB offers better performance or not. .. _CUB: http://nvlabs.github.io/cub/ ## Instruction: Fix documents to reflect CUPY_ACCELERATORS ## Code After: -------- Routines -------- The following pages describe NumPy-compatible routines. These functions cover a subset of `NumPy routines <https://docs.scipy.org/doc/numpy/reference/routines.html>`_. .. currentmodule:: cupy .. toctree:: :maxdepth: 2 creation manipulation binary dtype fft functional indexing io linalg logic math pad polynomials random sorting statistics ext CUB/cuTENSOR backend for reduction routines ---------------------------------- Some CuPy reduction routines, including :func:`~cupy.sum`, :func:`~cupy.min`, :func:`~cupy.max`, :func:`~cupy.argmin`, :func:`~cupy.argmax`, and other functions built on top of them, can be accelerated by switching to the `CUB`_ or `cuTENSOR`_ backend. These backends can be enabled by setting ``CUPY_ACCELERATORS`` environement variable. Note that while in general the accelerated reductions are faster, there could be exceptions depending on the data layout. We recommend users to perform some benchmarks to determine whether CUB offers better performance or not. .. _CUB: https://nvlabs.github.io/cub/ .. _cuTENSOR: https://docs.nvidia.com/cuda/cutensor/index.html
9189b7bcdfa63612781bb512d2e00f5f7c1e4b29
demo/templates/demo/includes/product_block.html
demo/templates/demo/includes/product_block.html
{% load product_tags %} <hr> <h2>{{ block.value.title }}</h2> <section> <div> <ol class="row"> {% for block in blocks.value.products %} <li class="col-xs-6 col-sm-4 col-md-3 col-lg-3"> {% render_product block %} </li> {% endfor %} </ol> </div> </section>
{% load product_tags %} <hr> <h2> {{ block.value.title }} {% if block.value.subtitle %} <br><small>{{ block.value.subtitle }}</small> {% endif %} </h2> <section> <div> <ol class="row"> {% for block in blocks.value.products %} <li class="col-xs-6 col-sm-4 col-md-3 col-lg-3"> {% render_product block %} </li> {% endfor %} </ol> </div> </section>
Add subtitle to product block
Add subtitle to product block
HTML
mit
pgovers/oscar-wagtail-demo,pgovers/oscar-wagtail-demo
html
## Code Before: {% load product_tags %} <hr> <h2>{{ block.value.title }}</h2> <section> <div> <ol class="row"> {% for block in blocks.value.products %} <li class="col-xs-6 col-sm-4 col-md-3 col-lg-3"> {% render_product block %} </li> {% endfor %} </ol> </div> </section> ## Instruction: Add subtitle to product block ## Code After: {% load product_tags %} <hr> <h2> {{ block.value.title }} {% if block.value.subtitle %} <br><small>{{ block.value.subtitle }}</small> {% endif %} </h2> <section> <div> <ol class="row"> {% for block in blocks.value.products %} <li class="col-xs-6 col-sm-4 col-md-3 col-lg-3"> {% render_product block %} </li> {% endfor %} </ol> </div> </section>
7a643a1c066db8ba1e9e5b645a53db7092373023
examples/simple/project.clj
examples/simple/project.clj
(defproject simple "0.10.10-SNAPSHOT" :dependencies [[org.clojure/clojure "1.10.1"] [org.clojure/clojurescript "1.10.520" :exclusions [com.google.javascript/closure-compiler-unshaded org.clojure/google-closure-library]] [thheller/shadow-cljs "2.8.51"] [reagent "0.8.1"] [re-frame "0.10.9"]] :plugins [[lein-shadow "0.1.5"]] :clean-targets ^{:protect false} ["resources/public/js"] :shadow-cljs {:nrepl {:port 8777} :builds {:client {:target :browser :output-dir "resources/public/js" :modules {:client {:init-fn simple.core/run}} :devtools {:http-root "resources/public" :http-port 8280}}}})
(defproject simple "0.10.10-SNAPSHOT" :dependencies [[org.clojure/clojure "1.10.1"] [org.clojure/clojurescript "1.10.520" :exclusions [com.google.javascript/closure-compiler-unshaded org.clojure/google-closure-library]] [thheller/shadow-cljs "2.8.51"] [reagent "0.8.1"] [re-frame "0.10.9"]] :plugins [[lein-shadow "0.1.5"]] :clean-targets ^{:protect false} [:target-path ".shadow-cljs" "shadow-cljs.edn" "package.json" "package-lock.json" "resources/public/js"] :shadow-cljs {:nrepl {:port 8777} :builds {:client {:target :browser :output-dir "resources/public/js" :modules {:client {:init-fn simple.core/run}} :devtools {:http-root "resources/public" :http-port 8280}}}})
Add more paths to :clean-targets for simple example
Add more paths to :clean-targets for simple example
Clojure
mit
Day8/re-frame,Day8/re-frame,Day8/re-frame
clojure
## Code Before: (defproject simple "0.10.10-SNAPSHOT" :dependencies [[org.clojure/clojure "1.10.1"] [org.clojure/clojurescript "1.10.520" :exclusions [com.google.javascript/closure-compiler-unshaded org.clojure/google-closure-library]] [thheller/shadow-cljs "2.8.51"] [reagent "0.8.1"] [re-frame "0.10.9"]] :plugins [[lein-shadow "0.1.5"]] :clean-targets ^{:protect false} ["resources/public/js"] :shadow-cljs {:nrepl {:port 8777} :builds {:client {:target :browser :output-dir "resources/public/js" :modules {:client {:init-fn simple.core/run}} :devtools {:http-root "resources/public" :http-port 8280}}}}) ## Instruction: Add more paths to :clean-targets for simple example ## Code After: (defproject simple "0.10.10-SNAPSHOT" :dependencies [[org.clojure/clojure "1.10.1"] [org.clojure/clojurescript "1.10.520" :exclusions [com.google.javascript/closure-compiler-unshaded org.clojure/google-closure-library]] [thheller/shadow-cljs "2.8.51"] [reagent "0.8.1"] [re-frame "0.10.9"]] :plugins [[lein-shadow "0.1.5"]] :clean-targets ^{:protect false} [:target-path ".shadow-cljs" "shadow-cljs.edn" "package.json" "package-lock.json" "resources/public/js"] :shadow-cljs {:nrepl {:port 8777} :builds {:client {:target :browser :output-dir "resources/public/js" :modules {:client {:init-fn simple.core/run}} :devtools {:http-root "resources/public" :http-port 8280}}}})
8a7061a6edcbf14d0cc3db3bea7ea9d9e30e301a
app/scripts/directives/fielddrop.js
app/scripts/directives/fielddrop.js
'use strict'; angular.module('vleApp') .directive('fieldDrop', function (Dataset) { return { templateUrl: 'templates/fielddrop.html', restrict: 'E', scope: { fieldDef: '=', types: '=' }, controller: function ($scope) { $scope.removeField = function() { $scope.fieldDef.name = null; $scope.fieldDef.type = null; }; $scope.fieldDropped = function() { $scope.fieldDef.type = Dataset.stats[$scope.fieldDef.name].type; } } }; });
'use strict'; angular.module('vleApp') .directive('fieldDrop', function (Dataset) { return { templateUrl: 'templates/fielddrop.html', restrict: 'E', scope: { fieldDef: '=', types: '=' }, controller: function ($scope) { $scope.removeField = function() { $scope.fieldDef.name = null; $scope.fieldDef.type = null; }; $scope.fieldDropped = function() { var fieldType = Dataset.stats[$scope.fieldDef.name].type; if (_.contains($scope.types, fieldType)) { $scope.fieldDef.type = fieldType; } else if (!$scope.fieldDef.type) { $scope.fieldDef.type = $scope.types[0]; } } } }; });
Fix problem with dropping Q on enc that only supports O (for example)
Fix problem with dropping Q on enc that only supports O (for example)
JavaScript
bsd-3-clause
sandbox/polestar,uwdata/polestar,vivekratnavel/polestar,jsanch/polestar,smartpcr/polestar,pallavkul/polestar,hortonworks/polestar,pallavkul/polestar,dennari/hack-n-hackers-polestar,zegang/polestar,dennari/hack-n-hackers-polestar,zegang/polestar,hortonworks/polestar,dennari/hack-n-hackers-polestar,vivekratnavel/polestar,sandbox/polestar,vega/polestar,jsanch/polestar,uwdata/polestar,vega/polestar,hortonworks/polestar,vivekratnavel/polestar,pallavkul/polestar,smartpcr/polestar,zegang/polestar,vega/polestar,sandbox/polestar,jsanch/polestar,smartpcr/polestar,uwdata/polestar
javascript
## Code Before: 'use strict'; angular.module('vleApp') .directive('fieldDrop', function (Dataset) { return { templateUrl: 'templates/fielddrop.html', restrict: 'E', scope: { fieldDef: '=', types: '=' }, controller: function ($scope) { $scope.removeField = function() { $scope.fieldDef.name = null; $scope.fieldDef.type = null; }; $scope.fieldDropped = function() { $scope.fieldDef.type = Dataset.stats[$scope.fieldDef.name].type; } } }; }); ## Instruction: Fix problem with dropping Q on enc that only supports O (for example) ## Code After: 'use strict'; angular.module('vleApp') .directive('fieldDrop', function (Dataset) { return { templateUrl: 'templates/fielddrop.html', restrict: 'E', scope: { fieldDef: '=', types: '=' }, controller: function ($scope) { $scope.removeField = function() { $scope.fieldDef.name = null; $scope.fieldDef.type = null; }; $scope.fieldDropped = function() { var fieldType = Dataset.stats[$scope.fieldDef.name].type; if (_.contains($scope.types, fieldType)) { $scope.fieldDef.type = fieldType; } else if (!$scope.fieldDef.type) { $scope.fieldDef.type = $scope.types[0]; } } } }; });
98daa4f2e208ed74a45c6f1584a89f89538326d7
build.gradle.kts
build.gradle.kts
plugins { val kotlinVersion = "1.3.71" kotlin("js") version kotlinVersion apply false kotlin("jvm") version kotlinVersion apply false kotlin("multiplatform") version kotlinVersion apply false kotlin("plugin.spring") version kotlinVersion apply false id("org.jetbrains.kotlin.plugin.serialization") version kotlinVersion apply false id("org.jlleitschuh.gradle.ktlint") version "9.1.1" apply false } subprojects { repositories { // while jcenter sync is broken for krossbow maven(url = "https://dl.bintray.com/joffrey-bion/maven") jcenter() } tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> { kotlinOptions.jvmTarget = "1.8" } tasks.withType<org.jetbrains.kotlin.gradle.tasks.Kotlin2JsCompile> { kotlinOptions.freeCompilerArgs = listOf("-Xuse-experimental=kotlin.Experimental") } afterEvaluate { // The import ordering expected by ktlint is alphabetical, which doesn't match IDEA's formatter. // Since it is not configurable, we have to disable the rule. // https://github.com/pinterest/ktlint/issues/527 extensions.configure<org.jlleitschuh.gradle.ktlint.KtlintExtension> { disabledRules.set(setOf("import-ordering", "no-wildcard-imports")) } } }
plugins { val kotlinVersion = "1.3.71" kotlin("js") version kotlinVersion apply false kotlin("jvm") version kotlinVersion apply false kotlin("multiplatform") version kotlinVersion apply false kotlin("plugin.spring") version kotlinVersion apply false id("org.jetbrains.kotlin.plugin.serialization") version kotlinVersion apply false id("org.jlleitschuh.gradle.ktlint") version "9.1.1" apply false } subprojects { repositories { jcenter() } tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> { kotlinOptions.jvmTarget = "1.8" } tasks.withType<org.jetbrains.kotlin.gradle.tasks.Kotlin2JsCompile> { kotlinOptions.freeCompilerArgs = listOf("-Xuse-experimental=kotlin.Experimental") } afterEvaluate { // The import ordering expected by ktlint is alphabetical, which doesn't match IDEA's formatter. // Since it is not configurable, we have to disable the rule. // https://github.com/pinterest/ktlint/issues/527 extensions.configure<org.jlleitschuh.gradle.ktlint.KtlintExtension> { disabledRules.set(setOf("import-ordering", "no-wildcard-imports")) } } }
Remove personal bintray repo now that jcenter sync works
Remove personal bintray repo now that jcenter sync works
Kotlin
mit
luxons/seven-wonders,luxons/seven-wonders,luxons/seven-wonders
kotlin
## Code Before: plugins { val kotlinVersion = "1.3.71" kotlin("js") version kotlinVersion apply false kotlin("jvm") version kotlinVersion apply false kotlin("multiplatform") version kotlinVersion apply false kotlin("plugin.spring") version kotlinVersion apply false id("org.jetbrains.kotlin.plugin.serialization") version kotlinVersion apply false id("org.jlleitschuh.gradle.ktlint") version "9.1.1" apply false } subprojects { repositories { // while jcenter sync is broken for krossbow maven(url = "https://dl.bintray.com/joffrey-bion/maven") jcenter() } tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> { kotlinOptions.jvmTarget = "1.8" } tasks.withType<org.jetbrains.kotlin.gradle.tasks.Kotlin2JsCompile> { kotlinOptions.freeCompilerArgs = listOf("-Xuse-experimental=kotlin.Experimental") } afterEvaluate { // The import ordering expected by ktlint is alphabetical, which doesn't match IDEA's formatter. // Since it is not configurable, we have to disable the rule. // https://github.com/pinterest/ktlint/issues/527 extensions.configure<org.jlleitschuh.gradle.ktlint.KtlintExtension> { disabledRules.set(setOf("import-ordering", "no-wildcard-imports")) } } } ## Instruction: Remove personal bintray repo now that jcenter sync works ## Code After: plugins { val kotlinVersion = "1.3.71" kotlin("js") version kotlinVersion apply false kotlin("jvm") version kotlinVersion apply false kotlin("multiplatform") version kotlinVersion apply false kotlin("plugin.spring") version kotlinVersion apply false id("org.jetbrains.kotlin.plugin.serialization") version kotlinVersion apply false id("org.jlleitschuh.gradle.ktlint") version "9.1.1" apply false } subprojects { repositories { jcenter() } tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompile> { kotlinOptions.jvmTarget = "1.8" } tasks.withType<org.jetbrains.kotlin.gradle.tasks.Kotlin2JsCompile> { kotlinOptions.freeCompilerArgs = listOf("-Xuse-experimental=kotlin.Experimental") } afterEvaluate { // The import ordering expected by ktlint is alphabetical, which doesn't match IDEA's formatter. // Since it is not configurable, we have to disable the rule. // https://github.com/pinterest/ktlint/issues/527 extensions.configure<org.jlleitschuh.gradle.ktlint.KtlintExtension> { disabledRules.set(setOf("import-ordering", "no-wildcard-imports")) } } }
94e1fe2a8e039f67ec91bb79f7476697433de2ea
src/Occupied/MainBundle/Resources/public/js/filters.js
src/Occupied/MainBundle/Resources/public/js/filters.js
'use strict'; angular.module('occupied.filters', ['occupied.services']) /** * Filter to insert adjusted/ filled-in values for {city}, {population|...}, {area|...}, {year|...}. * * Population must be an integer with no commas. * Area must be an int or float with no commas. * Area will have unit (km^2) appended to the number. */ .filter('interpolate', ['$filter', 'basePopulation', 'baseArea', function($filter, basePopulation, baseArea) { return function(text, city) { text = text.replace(new RegExp('{city}', 'g'), city.name); text = text.replace(new RegExp('\\{population\\|([0-9]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseInt(capture) * city.population / basePopulation, 0); }); text = text.replace(new RegExp('\\{area\\|([0-9.]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseFloat(capture) * city.area / baseArea, 1) + ' km²'; }); text = text.replace(new RegExp('\\{year\\|([0-9]+)\\}', 'g'), function(match, capture) { return parseInt(capture) + (new Date()).getFullYear() - 1946; }); return text; }; }]);
'use strict'; angular.module('occupied.filters', ['occupied.services']) /** * Filter to insert adjusted/ filled-in values for {city}, {population|...}, {area|...}, {year|...}. * * Year must be a full 4-digit value. * Population must be an integer with no commas. * Area must be an int or float with no commas. * Area will have unit (km^2) appended to the number. */ .filter('interpolate', ['$filter', 'basePopulation', 'baseArea', function($filter, basePopulation, baseArea) { return function(text, city) { text = text.replace(new RegExp('{city}', 'g'), city.name); text = text.replace(new RegExp('\\{population\\|([0-9]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseInt(capture) * city.population / basePopulation, 0); }); text = text.replace(new RegExp('\\{area\\|([0-9.]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseFloat(capture) * city.area / baseArea, 1) + ' km²'; }); text = text.replace(new RegExp('\\{year\\|([0-9]{4})\\}', 'g'), function(match, capture) { return parseInt(capture) + (new Date()).getFullYear() - 1946; }); return text; }; }]);
Document year filter spec and only attempt to use it with 4 digit values
Document year filter spec and only attempt to use it with 4 digit values
JavaScript
mit
webful-ltd/occupied-city,webful-ltd/occupied-city
javascript
## Code Before: 'use strict'; angular.module('occupied.filters', ['occupied.services']) /** * Filter to insert adjusted/ filled-in values for {city}, {population|...}, {area|...}, {year|...}. * * Population must be an integer with no commas. * Area must be an int or float with no commas. * Area will have unit (km^2) appended to the number. */ .filter('interpolate', ['$filter', 'basePopulation', 'baseArea', function($filter, basePopulation, baseArea) { return function(text, city) { text = text.replace(new RegExp('{city}', 'g'), city.name); text = text.replace(new RegExp('\\{population\\|([0-9]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseInt(capture) * city.population / basePopulation, 0); }); text = text.replace(new RegExp('\\{area\\|([0-9.]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseFloat(capture) * city.area / baseArea, 1) + ' km²'; }); text = text.replace(new RegExp('\\{year\\|([0-9]+)\\}', 'g'), function(match, capture) { return parseInt(capture) + (new Date()).getFullYear() - 1946; }); return text; }; }]); ## Instruction: Document year filter spec and only attempt to use it with 4 digit values ## Code After: 'use strict'; angular.module('occupied.filters', ['occupied.services']) /** * Filter to insert adjusted/ filled-in values for {city}, {population|...}, {area|...}, {year|...}. * * Year must be a full 4-digit value. * Population must be an integer with no commas. * Area must be an int or float with no commas. * Area will have unit (km^2) appended to the number. */ .filter('interpolate', ['$filter', 'basePopulation', 'baseArea', function($filter, basePopulation, baseArea) { return function(text, city) { text = text.replace(new RegExp('{city}', 'g'), city.name); text = text.replace(new RegExp('\\{population\\|([0-9]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseInt(capture) * city.population / basePopulation, 0); }); text = text.replace(new RegExp('\\{area\\|([0-9.]+)\\}', 'g'), function(match, capture) { return $filter('number')(parseFloat(capture) * city.area / baseArea, 1) + ' km²'; }); text = text.replace(new RegExp('\\{year\\|([0-9]{4})\\}', 'g'), function(match, capture) { return parseInt(capture) + (new Date()).getFullYear() - 1946; }); return text; }; }]);
367c9afa815d4d5b25663be1bc09ebe8393e6ed4
config/plugins.txt
config/plugins.txt
ant:1.2 antisamy-markup-formatter:1.3 credentials:1.22 cvs:2.12 durable-task:1.5 external-monitor-job:1.4 git:2.3.5 git-client:1.17.0 git-server:1.6 javadoc:1.3 junit:1.6 ldap:1.11 mailer:1.15 mapdb-api:1.0.6.0 matrix-auth:1.2 matrix-project:1.4.1 maven-plugin:2.9 pam-auth:1.2 scm-api:0.2 script-security:1.14 ssh-credentials:1.11 ssh-slaves:1.9 subversion:2.5 translation:1.12 windows-slaves:1.0 workflow-aggregator:1.6 workflow-api:1.6 workflow-basic-steps:1.6 workflow-cps:1.6 workflow-cps-global-lib:1.6 workflow-durable-task-step:1.6 workflow-job:1.6 workflow-scm-step:1.6 workflow-step-api:1.6 workflow-support:1.6
ant:1.2 antisamy-markup-formatter:1.3 credentials:1.22 cvs:2.12 durable-task:1.5 external-monitor-job:1.4 git:2.3.5 git-client:1.17.1 git-server:1.6 gitlab-plugin:1.1.23 javadoc:1.3 junit:1.6 ldap:1.11 mailer:1.15 mapdb-api:1.0.6.0 matrix-auth:1.2 matrix-project:1.4.1 maven-plugin:2.9 pam-auth:1.2 scm-api:0.2 script-security:1.14 ssh-credentials:1.11 ssh-slaves:1.9 subversion:2.5 translation:1.12 windows-slaves:1.0 workflow-aggregator:1.6 workflow-api:1.6 workflow-basic-steps:1.6 workflow-cps:1.6 workflow-cps-global-lib:1.6 workflow-durable-task-step:1.6 workflow-job:1.6 workflow-scm-step:1.6 workflow-step-api:1.6 workflow-support:1.6
Add gitlab-plugin and update git-client
Add gitlab-plugin and update git-client
Text
mit
xpfriend/pocci-image-jenkins
text
## Code Before: ant:1.2 antisamy-markup-formatter:1.3 credentials:1.22 cvs:2.12 durable-task:1.5 external-monitor-job:1.4 git:2.3.5 git-client:1.17.0 git-server:1.6 javadoc:1.3 junit:1.6 ldap:1.11 mailer:1.15 mapdb-api:1.0.6.0 matrix-auth:1.2 matrix-project:1.4.1 maven-plugin:2.9 pam-auth:1.2 scm-api:0.2 script-security:1.14 ssh-credentials:1.11 ssh-slaves:1.9 subversion:2.5 translation:1.12 windows-slaves:1.0 workflow-aggregator:1.6 workflow-api:1.6 workflow-basic-steps:1.6 workflow-cps:1.6 workflow-cps-global-lib:1.6 workflow-durable-task-step:1.6 workflow-job:1.6 workflow-scm-step:1.6 workflow-step-api:1.6 workflow-support:1.6 ## Instruction: Add gitlab-plugin and update git-client ## Code After: ant:1.2 antisamy-markup-formatter:1.3 credentials:1.22 cvs:2.12 durable-task:1.5 external-monitor-job:1.4 git:2.3.5 git-client:1.17.1 git-server:1.6 gitlab-plugin:1.1.23 javadoc:1.3 junit:1.6 ldap:1.11 mailer:1.15 mapdb-api:1.0.6.0 matrix-auth:1.2 matrix-project:1.4.1 maven-plugin:2.9 pam-auth:1.2 scm-api:0.2 script-security:1.14 ssh-credentials:1.11 ssh-slaves:1.9 subversion:2.5 translation:1.12 windows-slaves:1.0 workflow-aggregator:1.6 workflow-api:1.6 workflow-basic-steps:1.6 workflow-cps:1.6 workflow-cps-global-lib:1.6 workflow-durable-task-step:1.6 workflow-job:1.6 workflow-scm-step:1.6 workflow-step-api:1.6 workflow-support:1.6
0cabf3c4dae3599e2d1627ff41707cf36b4d2ddd
acoustics/__init__.py
acoustics/__init__.py
import acoustics.ambisonics import acoustics.utils import acoustics.octave import acoustics.doppler import acoustics.signal import acoustics.directivity import acoustics.building import acoustics.room import acoustics.standards import acoustics.cepstrum from acoustics._signal import Signal
import acoustics.aio import acoustics.ambisonics import acoustics.atmosphere import acoustics.bands import acoustics.building import acoustics.cepstrum import acoustics.criterion import acoustics.decibel import acoustics.descriptors import acoustics.directivity import acoustics.doppler import acoustics.generator import acoustics.imaging import acoustics.octave import acoustics.power import acoustics.quantity import acoustics.reflection import acoustics.room import acoustics.signal import acoustics.turbulence #import acoustics.utils import acoustics.weighting from acoustics._signal import Signal
Load all modules by default
Load all modules by default
Python
bsd-3-clause
python-acoustics/python-acoustics,antiface/python-acoustics,FRidh/python-acoustics,felipeacsi/python-acoustics,giumas/python-acoustics
python
## Code Before: import acoustics.ambisonics import acoustics.utils import acoustics.octave import acoustics.doppler import acoustics.signal import acoustics.directivity import acoustics.building import acoustics.room import acoustics.standards import acoustics.cepstrum from acoustics._signal import Signal ## Instruction: Load all modules by default ## Code After: import acoustics.aio import acoustics.ambisonics import acoustics.atmosphere import acoustics.bands import acoustics.building import acoustics.cepstrum import acoustics.criterion import acoustics.decibel import acoustics.descriptors import acoustics.directivity import acoustics.doppler import acoustics.generator import acoustics.imaging import acoustics.octave import acoustics.power import acoustics.quantity import acoustics.reflection import acoustics.room import acoustics.signal import acoustics.turbulence #import acoustics.utils import acoustics.weighting from acoustics._signal import Signal
82fe0c4d03652463916146d9d707383f4f360f22
webpack.config.js
webpack.config.js
var path = require("path"); var webpack = require("webpack"); var ParallelEsPlugin = require("parallel-es-webpack-plugin"); module.exports = { devtool: "#inline-source-map", entry: { examples: "./src/browser-example.ts", "performance-measurements": "./src/performance-measurement.ts" }, output: { path: path.resolve(__dirname, "dist"), pathinfo: true, filename: "[name].js" }, resolve: { extensions: [".webpack.js", ".web.js", ".ts", ".js"] }, module: { loaders: [ { test: /\.ts$/, exclude: path.resolve("./src/transpiled"), loader: "babel!awesome-typescript-loader" }, { test: /\.ts$/, include: path.resolve("./src/transpiled"), loader: `babel?${JSON.stringify({"plugins": [ "parallel-es"] })}!awesome-typescript-loader` }, { test: /\.parallel-es6\.js/, loader: "source-map" } ], noParse: [ /benchmark\/benchmark\.js/ ] }, devServer: { stats: { chunks: false } }, plugins: [ new webpack.optimize.CommonsChunkPlugin("common"), new ParallelEsPlugin({ babelOptions: { "presets": [ ["es2015", { "modules": false }] ] } }) ] };
var path = require("path"); var webpack = require("webpack"); var ParallelEsPlugin = require("parallel-es-webpack-plugin"); module.exports = { devtool: "#inline-source-map", entry: { examples: "./src/browser-example.ts", "performance-measurements": "./src/performance-measurement.ts" }, output: { path: path.resolve(__dirname, "dist"), pathinfo: true, filename: "[name].js" }, module: { loaders: [ { test: /\.ts$/, exclude: path.resolve("./src/transpiled"), loader: "babel!awesome-typescript-loader" }, { test: /\.ts$/, include: path.resolve("./src/transpiled"), loader: `babel?${JSON.stringify({"plugins": [ "parallel-es"] })}!awesome-typescript-loader` }, { test: /\.parallel-es6\.js/, loader: "source-map" } ], noParse: [ /benchmark\/benchmark\.js/ ] }, resolve: { extensions: [".webpack.js", ".web.js", ".ts", ".js"], modules:[ path.join(__dirname, "node_modules") ] }, devServer: { stats: { chunks: false } }, plugins: [ new webpack.optimize.CommonsChunkPlugin("common"), new ParallelEsPlugin({ babelOptions: { "presets": [ ["es2015", { "modules": false }] ] } }) ] };
Fix webpack setup for linked parallel-es
Fix webpack setup for linked parallel-es If the parallel-es module is linked, dependencies imported from transpiled functions can no longer be resolved. Requires to set resolve.modules to the project directory
JavaScript
mit
MichaReiser/parallel-es-example,MichaReiser/parallel-es-example,MichaReiser/parallel-es-example,MichaReiser/parallel-es-example,MichaReiser/parallel-es-example
javascript
## Code Before: var path = require("path"); var webpack = require("webpack"); var ParallelEsPlugin = require("parallel-es-webpack-plugin"); module.exports = { devtool: "#inline-source-map", entry: { examples: "./src/browser-example.ts", "performance-measurements": "./src/performance-measurement.ts" }, output: { path: path.resolve(__dirname, "dist"), pathinfo: true, filename: "[name].js" }, resolve: { extensions: [".webpack.js", ".web.js", ".ts", ".js"] }, module: { loaders: [ { test: /\.ts$/, exclude: path.resolve("./src/transpiled"), loader: "babel!awesome-typescript-loader" }, { test: /\.ts$/, include: path.resolve("./src/transpiled"), loader: `babel?${JSON.stringify({"plugins": [ "parallel-es"] })}!awesome-typescript-loader` }, { test: /\.parallel-es6\.js/, loader: "source-map" } ], noParse: [ /benchmark\/benchmark\.js/ ] }, devServer: { stats: { chunks: false } }, plugins: [ new webpack.optimize.CommonsChunkPlugin("common"), new ParallelEsPlugin({ babelOptions: { "presets": [ ["es2015", { "modules": false }] ] } }) ] }; ## Instruction: Fix webpack setup for linked parallel-es If the parallel-es module is linked, dependencies imported from transpiled functions can no longer be resolved. Requires to set resolve.modules to the project directory ## Code After: var path = require("path"); var webpack = require("webpack"); var ParallelEsPlugin = require("parallel-es-webpack-plugin"); module.exports = { devtool: "#inline-source-map", entry: { examples: "./src/browser-example.ts", "performance-measurements": "./src/performance-measurement.ts" }, output: { path: path.resolve(__dirname, "dist"), pathinfo: true, filename: "[name].js" }, module: { loaders: [ { test: /\.ts$/, exclude: path.resolve("./src/transpiled"), loader: "babel!awesome-typescript-loader" }, { test: /\.ts$/, include: path.resolve("./src/transpiled"), loader: `babel?${JSON.stringify({"plugins": [ "parallel-es"] })}!awesome-typescript-loader` }, { test: /\.parallel-es6\.js/, loader: "source-map" } ], noParse: [ /benchmark\/benchmark\.js/ ] }, resolve: { extensions: [".webpack.js", ".web.js", ".ts", ".js"], modules:[ path.join(__dirname, "node_modules") ] }, devServer: { stats: { chunks: false } }, plugins: [ new webpack.optimize.CommonsChunkPlugin("common"), new ParallelEsPlugin({ babelOptions: { "presets": [ ["es2015", { "modules": false }] ] } }) ] };
583a71cf2d61f7908fa44f9bb153629e0eca222a
db/migrate/20160421084217_add_output_elements_for_merit.rb
db/migrate/20160421084217_add_output_elements_for_merit.rb
class AddOutputElementsForMerit < ActiveRecord::Migration def change merit_order_price_curve = OutputElement.create!( group: 'Merit', key: 'merit_order_price_curve', requires_merit_order: true, output_element_type_id: 16 ) OutputElementSerie.create!( label: 'merit_price', color: '#5D7929', gquery: 'merit_order_price_curve', output_element: merit_order_price_curve, unit: "EUR/MWh" ) end end
class AddOutputElementsForMerit < ActiveRecord::Migration def change merit_order_price_curve = OutputElement.create!( group: 'Merit', key: 'merit_order_price_curve', requires_merit_order: true, output_element_type_id: 16, unit: "EUR/MWh" ) OutputElementSerie.create!( label: 'merit_price', color: '#5D7929', gquery: 'merit_order_price_curve', output_element: merit_order_price_curve ) end end
Fix M/O price chart migration to set unit
Fix M/O price chart migration to set unit
Ruby
mit
quintel/etmodel,quintel/etmodel,quintel/etmodel,quintel/etmodel
ruby
## Code Before: class AddOutputElementsForMerit < ActiveRecord::Migration def change merit_order_price_curve = OutputElement.create!( group: 'Merit', key: 'merit_order_price_curve', requires_merit_order: true, output_element_type_id: 16 ) OutputElementSerie.create!( label: 'merit_price', color: '#5D7929', gquery: 'merit_order_price_curve', output_element: merit_order_price_curve, unit: "EUR/MWh" ) end end ## Instruction: Fix M/O price chart migration to set unit ## Code After: class AddOutputElementsForMerit < ActiveRecord::Migration def change merit_order_price_curve = OutputElement.create!( group: 'Merit', key: 'merit_order_price_curve', requires_merit_order: true, output_element_type_id: 16, unit: "EUR/MWh" ) OutputElementSerie.create!( label: 'merit_price', color: '#5D7929', gquery: 'merit_order_price_curve', output_element: merit_order_price_curve ) end end
f01dce1bc592879b3c848b1762fdfc1aee2da6d9
vim/config/relative_linenumbers.vim
vim/config/relative_linenumbers.vim
set number " Show the line number of the line under the cursor let g:relative_linenumbers = get(g:, 'relative_linenumbers', "1") function! TurnOn() if (g:relative_linenumbers == "1") setlocal relativenumber endif endfunction function! TurnOff() if (g:relative_linenumbers == "1") setlocal norelativenumber endif endfunction " Auto toggle `relativenumber` when switching buffers augroup vimrc_set_relativenumber_only_active_window autocmd! autocmd VimEnter,BufWinEnter,WinEnter * call TurnOn() autocmd WinLeave * call TurnOff() augroup END
set number " Show the line number of the line under the cursor let g:relative_linenumbers = get(g:, 'relative_linenumbers', "1") nmap yort :call ToggleRelativeLineNumbers()<CR> function! ToggleRelativeLineNumbers() if (g:relative_linenumbers == "1") let g:relative_linenumbers = 0 setlocal norelativenumber else let g:relative_linenumbers = 1 setlocal relativenumber endif endfunction function! s:Enter() if (g:relative_linenumbers == "1") setlocal relativenumber endif endfunction function! s:Leave() if (g:relative_linenumbers == "1") setlocal norelativenumber endif endfunction " Auto toggle `relativenumber` when switching buffers augroup vimrc_set_relativenumber_only_active_window autocmd! autocmd VimEnter,BufWinEnter,WinEnter * call s:Enter() autocmd WinLeave * call s:Leave() augroup END
Add proper `yort` toggle for the buffer autocmds
Add proper `yort` toggle for the buffer autocmds
VimL
mit
randallagordon/dotfiles,randallagordon/dotfiles,randallagordon/dotfiles,randallagordon/dotfiles
viml
## Code Before: set number " Show the line number of the line under the cursor let g:relative_linenumbers = get(g:, 'relative_linenumbers', "1") function! TurnOn() if (g:relative_linenumbers == "1") setlocal relativenumber endif endfunction function! TurnOff() if (g:relative_linenumbers == "1") setlocal norelativenumber endif endfunction " Auto toggle `relativenumber` when switching buffers augroup vimrc_set_relativenumber_only_active_window autocmd! autocmd VimEnter,BufWinEnter,WinEnter * call TurnOn() autocmd WinLeave * call TurnOff() augroup END ## Instruction: Add proper `yort` toggle for the buffer autocmds ## Code After: set number " Show the line number of the line under the cursor let g:relative_linenumbers = get(g:, 'relative_linenumbers', "1") nmap yort :call ToggleRelativeLineNumbers()<CR> function! ToggleRelativeLineNumbers() if (g:relative_linenumbers == "1") let g:relative_linenumbers = 0 setlocal norelativenumber else let g:relative_linenumbers = 1 setlocal relativenumber endif endfunction function! s:Enter() if (g:relative_linenumbers == "1") setlocal relativenumber endif endfunction function! s:Leave() if (g:relative_linenumbers == "1") setlocal norelativenumber endif endfunction " Auto toggle `relativenumber` when switching buffers augroup vimrc_set_relativenumber_only_active_window autocmd! autocmd VimEnter,BufWinEnter,WinEnter * call s:Enter() autocmd WinLeave * call s:Leave() augroup END
8a3c2ff2a93a5102f06b275bdab5afc3cb3ce019
.travis.yml
.travis.yml
language: python before_install: - time pip install pep8 script: - pep8 --ignore E201,E202,E501 .
language: python before_install: - time pip install pep8 script: - pep8 --ignore E201,E202 --max-line-length=120 --exclude='migrations' .
Set max line lenght to 120 for pep8
Set max line lenght to 120 for pep8
YAML
bsd-3-clause
stepanovsh/project_template,mistalaba/cookiecutter-django,b-kolodziej/cookiecutter-django,ryankanno/cookiecutter-django,IanLee1521/cookiecutter-django,javipalanca/cookiecutter-django,Sushantgakhar/cookiecutter-django,ad-m/cookiecutter-django,mjhea0/cookiecutter-django,bopo/cookiecutter-django,webspired/cookiecutter-django,webyneter/cookiecutter-django,Nene-Padi/cookiecutter-django,jondelmil/cookiecutter-django,HandyCodeJob/hcj-django-temp,kaidokert/cookiecutter-django,hackultura/django-project-template,nunchaks/cookiecutter-django,trungdong/cookiecutter-django,hackultura/django-project-template,kaidokert/cookiecutter-django,hackebrot/cookiecutter-django,hairychris/cookiecutter-django,kaidokert/cookiecutter-django,hairychris/cookiecutter-django,bopo/cookiecutter-django,ryankanno/cookiecutter-django,gengue/django-new-marana,andela-ijubril/cookiecutter-django,drxos/cookiecutter-django-dokku,primoz-k/cookiecutter-django,luzfcb/cookiecutter-django,stepmr/cookiecutter-django,schacki/cookiecutter-django,stepanovsh/project_template,crdoconnor/cookiecutter-django,mjhea0/cookiecutter-django,webyneter/cookiecutter-django,hackebrot/cookiecutter-django,stepanovsh/project_template,stepmr/cookiecutter-django,kaidokert/cookiecutter-django,thornomad/cookiecutter-django,gappsexperts/cookiecutter-django,hackultura/django-project-template,ingenioustechie/cookiecutter-django-openshift,luzfcb/cookiecutter-django,nunchaks/cookiecutter-django,siauPatrick/cookiecutter-django,drxos/cookiecutter-django-dokku,aeikenberry/cookiecutter-django-rest-babel,topwebmaster/cookiecutter-django,yehoshuk/cookiecutter-django,ujjwalwahi/cookiecutter-django,gappsexperts/cookiecutter-django,HandyCodeJob/hcj-django-temp,topwebmaster/cookiecutter-django,the3ballsoft/django-new-marana,aleprovencio/cookiecutter-django,mjhea0/cookiecutter-django,aeikenberry/cookiecutter-django-rest-babel,pydanny/cookiecutter-django,b-kolodziej/cookiecutter-django,pydanny/cookiecutter-django,Sushantgakhar/cookiecutter-django,yunti/cookiecutter-django,ddiazpinto/cookiecutter-django,siauPatrick/cookiecutter-django,trungdong/cookiecutter-django,webspired/cookiecutter-django,wldcordeiro/cookiecutter-django-essentials,calculuscowboy/cookiecutter-django,ujjwalwahi/cookiecutter-django,chrisfranzen/cookiecutter-django,gengue/django-new-marana,yunti/cookiecutter-django,chrisfranzen/cookiecutter-django,HellerCommaA/cookiecutter-django,ovidner/cookiecutter-django,andela-ijubril/cookiecutter-django,bogdal/cookiecutter-django,trungdong/cookiecutter-django,topwebmaster/cookiecutter-django,HellerCommaA/cookiecutter-django,pydanny/cookiecutter-django,Sushantgakhar/cookiecutter-django,b-kolodziej/cookiecutter-django,kappataumu/cookiecutter-django,Sushantgakhar/cookiecutter-django,andela-ijubril/cookiecutter-django,audreyr/cookiecutter-django,denisKaranja/cookiecutter-django,gappsexperts/cookiecutter-django,Parbhat/cookiecutter-django-foundation,ryankanno/cookiecutter-django,ingenioustechie/cookiecutter-django-openshift,ujjwalwahi/cookiecutter-django,ovidner/cookiecutter-django,hairychris/cookiecutter-django,chrisfranzen/cookiecutter-django,HellerCommaA/cookiecutter-django,stepmr/cookiecutter-django,andela-ijubril/cookiecutter-django,andresgz/cookiecutter-django,ingenioustechie/cookiecutter-django-openshift,calculuscowboy/cookiecutter-django,javipalanca/cookiecutter-django,stepanovsh/project_template,audreyr/cookiecutter-django,gappsexperts/cookiecutter-django,ingenioustechie/cookiecutter-django-openshift,primoz-k/cookiecutter-django,wy123123/cookiecutter-django,rtorr/cookiecutter-django,Nene-Padi/cookiecutter-django,primoz-k/cookiecutter-django,aleprovencio/cookiecutter-django,wy123123/cookiecutter-django,audreyr/cookiecutter-django,javipalanca/cookiecutter-django,mistalaba/cookiecutter-django,siauPatrick/cookiecutter-django,chrisfranzen/cookiecutter-django,ad-m/cookiecutter-django,audreyr/cookiecutter-django,Parbhat/cookiecutter-django-foundation,Nene-Padi/cookiecutter-django,Parbhat/cookiecutter-django-foundation,mistalaba/cookiecutter-django,janusnic/cookiecutter-django,wldcordeiro/cookiecutter-django-essentials,thornomad/cookiecutter-django,mistalaba/cookiecutter-django,gengue/django-new-marana,rtorr/cookiecutter-django,trungdong/cookiecutter-django,aleprovencio/cookiecutter-django,siauPatrick/cookiecutter-django,drxos/cookiecutter-django-dokku,hackebrot/cookiecutter-django,bogdal/cookiecutter-django,martinblech/cookiecutter-django,aleprovencio/cookiecutter-django,aeikenberry/cookiecutter-django-rest-babel,janusnic/cookiecutter-django,bopo/cookiecutter-django,yehoshuk/cookiecutter-django,javipalanca/cookiecutter-django,IanLee1521/cookiecutter-django,martinblech/cookiecutter-django,drxos/cookiecutter-django-dokku,kappataumu/cookiecutter-django,thisjustin/cookiecutter-django,stepanovsh/project_template,HellerCommaA/cookiecutter-django,interaktiviti/cookiecutter-django,Nene-Padi/cookiecutter-django,andresgz/cookiecutter-django,stepmr/cookiecutter-django,wy123123/cookiecutter-django,the3ballsoft/django-new-marana,ryankanno/cookiecutter-django,asyncee/cookiecutter-django,luzfcb/cookiecutter-django,schacki/cookiecutter-django,primoz-k/cookiecutter-django,jondelmil/cookiecutter-django,webyneter/cookiecutter-django,crdoconnor/cookiecutter-django,bogdal/cookiecutter-django,nunchaks/cookiecutter-django,hackebrot/cookiecutter-django,hackultura/django-project-template,ujjwalwahi/cookiecutter-django,jondelmil/cookiecutter-django,denisKaranja/cookiecutter-django,martinblech/cookiecutter-django,aeikenberry/cookiecutter-django-rest-babel,nunchaks/cookiecutter-django,wldcordeiro/cookiecutter-django-essentials,calculuscowboy/cookiecutter-django,interaktiviti/cookiecutter-django,yunti/cookiecutter-django,bogdal/cookiecutter-django,Parbhat/cookiecutter-django-foundation,webspired/cookiecutter-django,hairychris/cookiecutter-django,IanLee1521/cookiecutter-django,HandyCodeJob/hcj-django-temp,yehoshuk/cookiecutter-django,janusnic/cookiecutter-django,asyncee/cookiecutter-django,ad-m/cookiecutter-django,andresgz/cookiecutter-django,janusnic/cookiecutter-django,ddiazpinto/cookiecutter-django,IanLee1521/cookiecutter-django,HandyCodeJob/hcj-django-temp,thornomad/cookiecutter-django,ovidner/cookiecutter-django,webspired/cookiecutter-django,thornomad/cookiecutter-django,jondelmil/cookiecutter-django,thisjustin/cookiecutter-django,bopo/cookiecutter-django,calculuscowboy/cookiecutter-django,thisjustin/cookiecutter-django,interaktiviti/cookiecutter-django,interaktiviti/cookiecutter-django,denisKaranja/cookiecutter-django,rtorr/cookiecutter-django,ddiazpinto/cookiecutter-django,ad-m/cookiecutter-django,luzfcb/cookiecutter-django,yehoshuk/cookiecutter-django,denisKaranja/cookiecutter-django,crdoconnor/cookiecutter-django,crdoconnor/cookiecutter-django,ovidner/cookiecutter-django,ddiazpinto/cookiecutter-django,andresgz/cookiecutter-django,kappataumu/cookiecutter-django,schacki/cookiecutter-django,asyncee/cookiecutter-django,yunti/cookiecutter-django,rtorr/cookiecutter-django,denisKaranja/cookiecutter-django,javipalanca/cookiecutter-django,pydanny/cookiecutter-django,webyneter/cookiecutter-django,mjhea0/cookiecutter-django,kappataumu/cookiecutter-django,wy123123/cookiecutter-django,b-kolodziej/cookiecutter-django,the3ballsoft/django-new-marana,martinblech/cookiecutter-django,asyncee/cookiecutter-django,topwebmaster/cookiecutter-django,schacki/cookiecutter-django,thisjustin/cookiecutter-django
yaml
## Code Before: language: python before_install: - time pip install pep8 script: - pep8 --ignore E201,E202,E501 . ## Instruction: Set max line lenght to 120 for pep8 ## Code After: language: python before_install: - time pip install pep8 script: - pep8 --ignore E201,E202 --max-line-length=120 --exclude='migrations' .
5844ddc45b725140edd858ed276b92a337f6b5ea
index.js
index.js
const Gitter = require('./gitter'); const Lexicon = require('./lexicon'); const client = new Gitter(); function listenAndReply(roomId) { client.readChatMessages(roomId, (message) => { if (message.operation === 'create') { if (message.model.fromUser.id === process.env.GITTER_LEXICON_USER_ID) return; let prefix = ''; if (roomId === process.env.GITTER_ESOUI_ROOM_ID) { if (!/^@?lex(icon)?/.test(message.model.text)) return; prefix += `@${message.model.fromUser.username} `; } Lexicon.parse(message.model.text, (text) => { client.sendChatMessage(roomId, `${prefix}${text}`); }); } }); } const rooms = []; client.watchRoomUpdates(process.env.GITTER_LEXICON_USER_ID, (message) => { const roomId = message.model.id; if (message.operation === 'create' || message.operation === 'patch') { if (message.operation === 'create') { Lexicon.parse('', (text) => { client.sendChatMessage(roomId, text); }); } if (rooms.indexOf(roomId) < 0) { listenAndReply(roomId); rooms.push(roomId); } } }); listenAndReply(process.env.GITTER_ESOUI_ROOM_ID);
const Gitter = require('./gitter'); const Lexicon = require('./lexicon'); const client = new Gitter(); function listenAndReply(roomId) { client.readChatMessages(roomId, (data) => { if (data.operation === 'create') { if (data.model.fromUser.id === process.env.GITTER_LEXICON_USER_ID) return; let prefix = ''; let message = data.model.text; if (roomId === process.env.GITTER_ESOUI_ROOM_ID) { const match = message.match(/^@?lex(icon)?(\s(.+)|$)/); if (!match) return; prefix += `@${data.model.fromUser.username} `; message = match[3]; } Lexicon.parse(message, (text) => { client.sendChatMessage(roomId, `${prefix}${text}`); }); } }); } const rooms = []; client.watchRoomUpdates(process.env.GITTER_LEXICON_USER_ID, (message) => { const roomId = message.model.id; if (message.operation === 'create' || message.operation === 'patch') { if (message.operation === 'create') { Lexicon.parse('', (text) => { client.sendChatMessage(roomId, text); }); } if (rooms.indexOf(roomId) < 0) { listenAndReply(roomId); rooms.push(roomId); } } }); listenAndReply(process.env.GITTER_ESOUI_ROOM_ID);
Fix bot trying to parse message with lexicon prefix
Fix bot trying to parse message with lexicon prefix
JavaScript
mit
esoui/lexicon,esoui/lexicon
javascript
## Code Before: const Gitter = require('./gitter'); const Lexicon = require('./lexicon'); const client = new Gitter(); function listenAndReply(roomId) { client.readChatMessages(roomId, (message) => { if (message.operation === 'create') { if (message.model.fromUser.id === process.env.GITTER_LEXICON_USER_ID) return; let prefix = ''; if (roomId === process.env.GITTER_ESOUI_ROOM_ID) { if (!/^@?lex(icon)?/.test(message.model.text)) return; prefix += `@${message.model.fromUser.username} `; } Lexicon.parse(message.model.text, (text) => { client.sendChatMessage(roomId, `${prefix}${text}`); }); } }); } const rooms = []; client.watchRoomUpdates(process.env.GITTER_LEXICON_USER_ID, (message) => { const roomId = message.model.id; if (message.operation === 'create' || message.operation === 'patch') { if (message.operation === 'create') { Lexicon.parse('', (text) => { client.sendChatMessage(roomId, text); }); } if (rooms.indexOf(roomId) < 0) { listenAndReply(roomId); rooms.push(roomId); } } }); listenAndReply(process.env.GITTER_ESOUI_ROOM_ID); ## Instruction: Fix bot trying to parse message with lexicon prefix ## Code After: const Gitter = require('./gitter'); const Lexicon = require('./lexicon'); const client = new Gitter(); function listenAndReply(roomId) { client.readChatMessages(roomId, (data) => { if (data.operation === 'create') { if (data.model.fromUser.id === process.env.GITTER_LEXICON_USER_ID) return; let prefix = ''; let message = data.model.text; if (roomId === process.env.GITTER_ESOUI_ROOM_ID) { const match = message.match(/^@?lex(icon)?(\s(.+)|$)/); if (!match) return; prefix += `@${data.model.fromUser.username} `; message = match[3]; } Lexicon.parse(message, (text) => { client.sendChatMessage(roomId, `${prefix}${text}`); }); } }); } const rooms = []; client.watchRoomUpdates(process.env.GITTER_LEXICON_USER_ID, (message) => { const roomId = message.model.id; if (message.operation === 'create' || message.operation === 'patch') { if (message.operation === 'create') { Lexicon.parse('', (text) => { client.sendChatMessage(roomId, text); }); } if (rooms.indexOf(roomId) < 0) { listenAndReply(roomId); rooms.push(roomId); } } }); listenAndReply(process.env.GITTER_ESOUI_ROOM_ID);
b7c8ca166c526e83f83305e4be72f6f4e9c66fda
app/views/layouts/_footer.html.haml
app/views/layouts/_footer.html.haml
.navbar-static-top.footer .container .row .span2 &copy; Code.org, 2013 %br/ = form_tag(locale_url, method: :post, id: 'localeForm') do = hidden_field_tag :return_to, request.url = select_tag :locale, options_for_select(options_for_locale_select, locale), onchange: 'switchLocale();' .span10 = link_to t('footer.feedback'), 'http://codeorg.uservoice.com/forums/228116-code-org-tutorials' = ' - ' = link_to t('footer.translate'), 'http://eepurl.com/H3Xtr' %br/ %br/ = t('footer.help_from_html') %br/ = t('footer.art_from_html') %br/ = link_to t('footer.tos'), 'http://code.org/tos' - if current_user && current_user.admin? %br/ Admin: = link_to "Games", games_path | = link_to "Concepts", concepts_path | = link_to "Videos", videos_path | = link_to "Recent Activity", all_usage_path
.navbar-static-top.footer .container .row .span2 &copy; Code.org, 2013 %br/ = form_tag(locale_url, method: :post, id: 'localeForm') do = hidden_field_tag :return_to, request.url = select_tag :locale, options_for_select(options_for_locale_select, locale), onchange: 'switchLocale();' .span10 = link_to t('footer.feedback'), 'http://codeorg.uservoice.com/forums/228116-code-org-tutorials' = ' - ' = link_to t('footer.translate'), 'https://docs.google.com/forms/d/1v72iM0reILSCbyJo4870yYXzMKmSXd9IlOc5usL3xQo/viewform' %br/ %br/ = t('footer.help_from_html') %br/ = t('footer.art_from_html') %br/ = link_to t('footer.tos'), 'http://code.org/tos' - if current_user && current_user.admin? %br/ Admin: = link_to "Games", games_path | = link_to "Concepts", concepts_path | = link_to "Videos", videos_path | = link_to "Recent Activity", all_usage_path
Revert "New translation help link"
Revert "New translation help link" This reverts commit 595fd3fad30c11bb4709f0784d36d029c7b19c34.
Haml
apache-2.0
tobyk100/dashboard,tobyk100/dashboard
haml
## Code Before: .navbar-static-top.footer .container .row .span2 &copy; Code.org, 2013 %br/ = form_tag(locale_url, method: :post, id: 'localeForm') do = hidden_field_tag :return_to, request.url = select_tag :locale, options_for_select(options_for_locale_select, locale), onchange: 'switchLocale();' .span10 = link_to t('footer.feedback'), 'http://codeorg.uservoice.com/forums/228116-code-org-tutorials' = ' - ' = link_to t('footer.translate'), 'http://eepurl.com/H3Xtr' %br/ %br/ = t('footer.help_from_html') %br/ = t('footer.art_from_html') %br/ = link_to t('footer.tos'), 'http://code.org/tos' - if current_user && current_user.admin? %br/ Admin: = link_to "Games", games_path | = link_to "Concepts", concepts_path | = link_to "Videos", videos_path | = link_to "Recent Activity", all_usage_path ## Instruction: Revert "New translation help link" This reverts commit 595fd3fad30c11bb4709f0784d36d029c7b19c34. ## Code After: .navbar-static-top.footer .container .row .span2 &copy; Code.org, 2013 %br/ = form_tag(locale_url, method: :post, id: 'localeForm') do = hidden_field_tag :return_to, request.url = select_tag :locale, options_for_select(options_for_locale_select, locale), onchange: 'switchLocale();' .span10 = link_to t('footer.feedback'), 'http://codeorg.uservoice.com/forums/228116-code-org-tutorials' = ' - ' = link_to t('footer.translate'), 'https://docs.google.com/forms/d/1v72iM0reILSCbyJo4870yYXzMKmSXd9IlOc5usL3xQo/viewform' %br/ %br/ = t('footer.help_from_html') %br/ = t('footer.art_from_html') %br/ = link_to t('footer.tos'), 'http://code.org/tos' - if current_user && current_user.admin? %br/ Admin: = link_to "Games", games_path | = link_to "Concepts", concepts_path | = link_to "Videos", videos_path | = link_to "Recent Activity", all_usage_path
4cc782bd715a9202b2b6eb1190fbf66eaab3d8f1
yalex/src/demo.c
yalex/src/demo.c
void replMessageCallback(const char* ptr) { if (ptr && strlen(ptr)>0) { printf("%s\n", ptr); } } int yalex(void) { yalex_world world; yalex_init(&world, replMessageCallback); replMessageCallback("welcome"); char word[256]; /**/ yalex_repl(&world, ":fibstep (R1R R2R + R3S R2R R1S R3R R2S R4R 1 + R4S rec)"); yalex_repl(&world, ":rec (R0R R4R 1 + < 'fibstep R3R select)"); yalex_repl(&world, ":fib (R0S 0 R1S 1 R2S 0 R3S 1 R4S rec)"); while (1) { word[0] = 0; fgets(word, sizeof(word), stdin); yalex_repl(&world, word); } return 0; } int main() { yalex(); return 0; }
void replMessageCallback(const char* ptr) { if (ptr && strlen(ptr)>0) { printf("%s\n", ptr); } } int yalex(void) { yalex_world world; yalex_init(&world, replMessageCallback); replMessageCallback("welcome"); char word[256]; /**/ yalex_repl(&world, ":nset (R0S)"); yalex_repl(&world, ":n (R0R)"); yalex_repl(&world, ":t1set (R1S)"); yalex_repl(&world, ":t1 (R1R)"); yalex_repl(&world, ":t2set (R2S)"); yalex_repl(&world, ":t2 (R2R)"); yalex_repl(&world, ":resset (R3S)"); yalex_repl(&world, ":res (R3R)"); yalex_repl(&world, ":iset (R4S)"); yalex_repl(&world, ":i (R4R)"); yalex_repl(&world, ":fibstep (t1 t2 + resset t2 t1set res t2set i 1 + iset rec)"); yalex_repl(&world, ":rec (n i 1 + < 'fibstep res select)"); yalex_repl(&world, ":fib (nset 0 t1set 1 t2set 0 resset 1 iset rec)"); while (1) { word[0] = 0; fgets(word, sizeof(word), stdin); yalex_repl(&world, word); } return 0; } int main() { yalex(); return 0; }
Add register alias for verbosity and readability?
Add register alias for verbosity and readability?
C
mit
AlexanderBrevig/yalex
c
## Code Before: void replMessageCallback(const char* ptr) { if (ptr && strlen(ptr)>0) { printf("%s\n", ptr); } } int yalex(void) { yalex_world world; yalex_init(&world, replMessageCallback); replMessageCallback("welcome"); char word[256]; /**/ yalex_repl(&world, ":fibstep (R1R R2R + R3S R2R R1S R3R R2S R4R 1 + R4S rec)"); yalex_repl(&world, ":rec (R0R R4R 1 + < 'fibstep R3R select)"); yalex_repl(&world, ":fib (R0S 0 R1S 1 R2S 0 R3S 1 R4S rec)"); while (1) { word[0] = 0; fgets(word, sizeof(word), stdin); yalex_repl(&world, word); } return 0; } int main() { yalex(); return 0; } ## Instruction: Add register alias for verbosity and readability? ## Code After: void replMessageCallback(const char* ptr) { if (ptr && strlen(ptr)>0) { printf("%s\n", ptr); } } int yalex(void) { yalex_world world; yalex_init(&world, replMessageCallback); replMessageCallback("welcome"); char word[256]; /**/ yalex_repl(&world, ":nset (R0S)"); yalex_repl(&world, ":n (R0R)"); yalex_repl(&world, ":t1set (R1S)"); yalex_repl(&world, ":t1 (R1R)"); yalex_repl(&world, ":t2set (R2S)"); yalex_repl(&world, ":t2 (R2R)"); yalex_repl(&world, ":resset (R3S)"); yalex_repl(&world, ":res (R3R)"); yalex_repl(&world, ":iset (R4S)"); yalex_repl(&world, ":i (R4R)"); yalex_repl(&world, ":fibstep (t1 t2 + resset t2 t1set res t2set i 1 + iset rec)"); yalex_repl(&world, ":rec (n i 1 + < 'fibstep res select)"); yalex_repl(&world, ":fib (nset 0 t1set 1 t2set 0 resset 1 iset rec)"); while (1) { word[0] = 0; fgets(word, sizeof(word), stdin); yalex_repl(&world, word); } return 0; } int main() { yalex(); return 0; }
6dedd448811335f9bae7db3aad87a15b910592a8
build.yml
build.yml
- build: gontinuum description: Build project gontinuum default: run - properties: name: "gontinuum" version: "0.1.0" build_dir: "build" src_dir: "src" main: "#{src_dir}/#{name}.go" etc_dir: "etc" etc_file: "#{etc_dir}/#{name}.yml" args: :etc_file - target: bin description: Make binary executable script: - mkdir: :build_dir - "go build -o #{build_dir}/#{name} #{main}" - target: run depends: bin description: Run gontinuum script: - "#{build_dir}/#{name} #{args}" - target: clean description: Delete generated files script: - rmdir: :build_dir
- build: gontinuum description: Build project gontinuum default: run - properties: name: "gontinuum" version: "0.1.0" bin_dir: "bin" src_dir: "src" main: "#{src_dir}/#{name}.go" etc_dir: "etc" etc_file: "#{etc_dir}/#{name}.yml" args: :etc_file - target: bin description: Make binary executable script: - rm: "#{bin_dir}/#{name}" - "go build -o #{bin_dir}/#{name} #{main}" - target: run depends: bin description: Run gontinuum script: - "#{bin_dir}/#{name} #{args}"
Build binary in bin directory
Build binary in bin directory
YAML
apache-2.0
c4s4/continuum,c4s4/gontinuum
yaml
## Code Before: - build: gontinuum description: Build project gontinuum default: run - properties: name: "gontinuum" version: "0.1.0" build_dir: "build" src_dir: "src" main: "#{src_dir}/#{name}.go" etc_dir: "etc" etc_file: "#{etc_dir}/#{name}.yml" args: :etc_file - target: bin description: Make binary executable script: - mkdir: :build_dir - "go build -o #{build_dir}/#{name} #{main}" - target: run depends: bin description: Run gontinuum script: - "#{build_dir}/#{name} #{args}" - target: clean description: Delete generated files script: - rmdir: :build_dir ## Instruction: Build binary in bin directory ## Code After: - build: gontinuum description: Build project gontinuum default: run - properties: name: "gontinuum" version: "0.1.0" bin_dir: "bin" src_dir: "src" main: "#{src_dir}/#{name}.go" etc_dir: "etc" etc_file: "#{etc_dir}/#{name}.yml" args: :etc_file - target: bin description: Make binary executable script: - rm: "#{bin_dir}/#{name}" - "go build -o #{bin_dir}/#{name} #{main}" - target: run depends: bin description: Run gontinuum script: - "#{bin_dir}/#{name} #{args}"
32c3aa6246f518c2d0126c1ba65380856741b456
radio/templates/registration/register.html
radio/templates/registration/register.html
{% extends "radio/site_base.html" %} {% load radio_extras %} {% block main-nav %} {% include "radio/site_live_nav.html" %} {% endblock %} {% load socialaccount %} {% block main-body %} <div class="container"> <div class="row"> <div class="col-xs-5"> <h1>Create an account</h1> You can use your Goggle account to create an account here <a href="{% provider_login_url "google" %}"><img src="/static/radio/img/btn_google_signin_dark_normal_web.png"></a> or create a new account below. <form method="post" action="/accounts/signup/">{% csrf_token %} <table border="0"> {{ form.as_table }} </table> <input type="submit" value="Register" /> </form> </div> <div class="col-xs-7"> <h3>Help</h3> <p>If you have any questions or comments you can email us at <a href="mailto:{% get_setting 'SITE_EMAIL' %}">{% get_setting 'SITE_EMAIL' %}</a>.</p> </p> </div> </div> </div> {% endblock %}
{% extends "radio/site_base.html" %} {% load radio_extras %} {% block main-nav %} {% include "radio/site_live_nav.html" %} {% endblock %} {% load socialaccount %} {% block main-body %} <div class="container"> <div class="row"> <div class="col-sm-12 col-md-8 col-lg-8"> <h1>Create an account</h1> You can use your Goggle account to create an account here <a href="{% provider_login_url "google" %}"><img src="/static/radio/img/btn_google_signin_dark_normal_web.png"></a> or create a new account below. <form method="post" action="/accounts/signup/">{% csrf_token %} <table border="0"> {{ form.as_table }} </table> <input type="submit" value="Register" /> </form> </div> <div class="col-md-4 col-lg-4"> <h3>Help</h3> <p>If you have any questions or comments you can email us at <a href="mailto:{% get_setting 'SITE_EMAIL' %}">{% get_setting 'SITE_EMAIL' %}</a>.</p> </p> </div> </div> </div> {% endblock %}
Fix css for registration on small devices
Fix css for registration on small devices
HTML
mit
ScanOC/trunk-player,ScanOC/trunk-player,ScanOC/trunk-player,ScanOC/trunk-player
html
## Code Before: {% extends "radio/site_base.html" %} {% load radio_extras %} {% block main-nav %} {% include "radio/site_live_nav.html" %} {% endblock %} {% load socialaccount %} {% block main-body %} <div class="container"> <div class="row"> <div class="col-xs-5"> <h1>Create an account</h1> You can use your Goggle account to create an account here <a href="{% provider_login_url "google" %}"><img src="/static/radio/img/btn_google_signin_dark_normal_web.png"></a> or create a new account below. <form method="post" action="/accounts/signup/">{% csrf_token %} <table border="0"> {{ form.as_table }} </table> <input type="submit" value="Register" /> </form> </div> <div class="col-xs-7"> <h3>Help</h3> <p>If you have any questions or comments you can email us at <a href="mailto:{% get_setting 'SITE_EMAIL' %}">{% get_setting 'SITE_EMAIL' %}</a>.</p> </p> </div> </div> </div> {% endblock %} ## Instruction: Fix css for registration on small devices ## Code After: {% extends "radio/site_base.html" %} {% load radio_extras %} {% block main-nav %} {% include "radio/site_live_nav.html" %} {% endblock %} {% load socialaccount %} {% block main-body %} <div class="container"> <div class="row"> <div class="col-sm-12 col-md-8 col-lg-8"> <h1>Create an account</h1> You can use your Goggle account to create an account here <a href="{% provider_login_url "google" %}"><img src="/static/radio/img/btn_google_signin_dark_normal_web.png"></a> or create a new account below. <form method="post" action="/accounts/signup/">{% csrf_token %} <table border="0"> {{ form.as_table }} </table> <input type="submit" value="Register" /> </form> </div> <div class="col-md-4 col-lg-4"> <h3>Help</h3> <p>If you have any questions or comments you can email us at <a href="mailto:{% get_setting 'SITE_EMAIL' %}">{% get_setting 'SITE_EMAIL' %}</a>.</p> </p> </div> </div> </div> {% endblock %}
b3e51144d3cb3308b2f2c85846d2e6d1c085bfca
src/Ruler.css
src/Ruler.css
:local(.component) { flex-shrink: 0; } :local(.hour) { text-align: right; padding: 2px 5px; }
:local(.component) { flex-shrink: 0; position: relative; background-color: #fff; } :local(.hour) { text-align: right; padding: 2px 5px; }
Set white background in left gutter to have a cleaner look.
Set white background in left gutter to have a cleaner look.
CSS
mit
trotzig/react-available-times,trotzig/react-available-times
css
## Code Before: :local(.component) { flex-shrink: 0; } :local(.hour) { text-align: right; padding: 2px 5px; } ## Instruction: Set white background in left gutter to have a cleaner look. ## Code After: :local(.component) { flex-shrink: 0; position: relative; background-color: #fff; } :local(.hour) { text-align: right; padding: 2px 5px; }
05823910c8dccb2912be4506615787ef321f0082
doc/cli/npm-run-script.md
doc/cli/npm-run-script.md
npm-run-script(1) -- Run arbitrary package scripts ================================================== ## SYNOPSIS npm run-script [<pkg>] [command] ## DESCRIPTION This runs an arbitrary command from a package's `"scripts"` object. If no package name is provided, it will search for a `package.json` in the current folder and use its `"scripts"` object. If no `"command"` is provided, it will list the available top level scripts. It is used by the test, start, restart, and stop commands, but can be called directly, as well. ## SEE ALSO * npm-scripts(7) * npm-test(1) * npm-start(1) * npm-restart(1) * npm-stop(1)
npm-run-script(1) -- Run arbitrary package scripts ================================================== ## SYNOPSIS npm run-script [<pkg>] [command] npm run [<pkg>] [command] ## DESCRIPTION This runs an arbitrary command from a package's `"scripts"` object. If no package name is provided, it will search for a `package.json` in the current folder and use its `"scripts"` object. If no `"command"` is provided, it will list the available top level scripts. It is used by the test, start, restart, and stop commands, but can be called directly, as well. ## SEE ALSO * npm-scripts(7) * npm-test(1) * npm-start(1) * npm-restart(1) * npm-stop(1)
Include alias run in run-script doc.
Include alias run in run-script doc. Correctly document run-script alias
Markdown
artistic-2.0
thomblake/npm,princeofdarkness76/npm,yodeyer/npm,yibn2008/npm,princeofdarkness76/npm,segrey/npm,Volune/npm,haggholm/npm,midniteio/npm,evocateur/npm,xalopp/npm,kemitchell/npm,midniteio/npm,lxe/npm,chadnickbok/npm,cchamberlain/npm-msys2,rsp/npm,yibn2008/npm,misterbyrne/npm,evanlucas/npm,segrey/npm,haggholm/npm,kimshinelove/naver-npm,Volune/npm,DIREKTSPEED-LTD/npm,chadnickbok/npm,lxe/npm,princeofdarkness76/npm,cchamberlain/npm,cchamberlain/npm-msys2,misterbyrne/npm,TimeToogo/npm,DaveEmmerson/npm,rsp/npm,ekmartin/npm,kemitchell/npm,thomblake/npm,cchamberlain/npm,TimeToogo/npm,cchamberlain/npm-msys2,evocateur/npm,kimshinelove/naver-npm,evanlucas/npm,evanlucas/npm,rsp/npm,DIREKTSPEED-LTD/npm,xalopp/npm,Volune/npm,yodeyer/npm,DaveEmmerson/npm,yodeyer/npm,kemitchell/npm,cchamberlain/npm,thomblake/npm,lxe/npm,haggholm/npm,DaveEmmerson/npm,ekmartin/npm,DIREKTSPEED-LTD/npm,TimeToogo/npm,xalopp/npm,misterbyrne/npm,ekmartin/npm,chadnickbok/npm,midniteio/npm,yibn2008/npm,segrey/npm,evocateur/npm,kimshinelove/naver-npm
markdown
## Code Before: npm-run-script(1) -- Run arbitrary package scripts ================================================== ## SYNOPSIS npm run-script [<pkg>] [command] ## DESCRIPTION This runs an arbitrary command from a package's `"scripts"` object. If no package name is provided, it will search for a `package.json` in the current folder and use its `"scripts"` object. If no `"command"` is provided, it will list the available top level scripts. It is used by the test, start, restart, and stop commands, but can be called directly, as well. ## SEE ALSO * npm-scripts(7) * npm-test(1) * npm-start(1) * npm-restart(1) * npm-stop(1) ## Instruction: Include alias run in run-script doc. Correctly document run-script alias ## Code After: npm-run-script(1) -- Run arbitrary package scripts ================================================== ## SYNOPSIS npm run-script [<pkg>] [command] npm run [<pkg>] [command] ## DESCRIPTION This runs an arbitrary command from a package's `"scripts"` object. If no package name is provided, it will search for a `package.json` in the current folder and use its `"scripts"` object. If no `"command"` is provided, it will list the available top level scripts. It is used by the test, start, restart, and stop commands, but can be called directly, as well. ## SEE ALSO * npm-scripts(7) * npm-test(1) * npm-start(1) * npm-restart(1) * npm-stop(1)
bed311edca218a8159b1dc209651648d617998b9
_includes/socialsharing.html
_includes/socialsharing.html
<div id="sharingContainer"> <!-- <button onclick="copyText()">share link</button> --> <div class="individualShare" id='{{page.title}}' onclick="copyText()"> Share Link </div> <a href="https://twitter.com/share" class="twitter-share-button" data-url="{site.baseurl}}/{{page.url}}?redirect=1" data-via="IFPRI" data-count="none" target="_blank"></a> <!-- <div class="g-plus" data-action="share" data-annotation="none"></div> --> <!-- <div class="fb-share-button" data-href="{{site.baseurl}}{{page.url}}" data-type="button"></div> --> <div class="fb-share-button" data-href="{{site.baseurl}}/{{page.url}}?redirect=1" data-type="button"></div> <div class="panel panel-default"> <div id="panel-body" class="panel-body"> </div> </div> </div>
<div id="sharingContainer"> <!-- <button onclick="copyText()">share link</button> --> <div class="individualShare" id='{{page.title}}' onclick="copyText()"> Share Link </div> <a href="https://twitter.com/share" class="twitter-share-button" url="{site.baseurl}}/{{page.url}}?redirect=1" data-via="IFPRI" data-count="none" target="_blank"></a> <!-- <div class="g-plus" data-action="share" data-annotation="none"></div> --> <!-- <div class="fb-share-button" data-href="{{site.baseurl}}{{page.url}}" data-type="button"></div> --> <div class="fb-share-button" data-href="{{site.baseurl}}/{{page.url}}?redirect=1" data-type="button"></div> <div class="panel panel-default"> <div id="panel-body" class="panel-body"> </div> </div> </div>
Edit data-url to twitter button1
Edit data-url to twitter button1
HTML
bsd-3-clause
IFPRMENA/arabspatialblog,IFPRMENA/arabspatialblog,IFPRMENA/arabspatialblog,IFPRMENA/arabspatialblog
html
## Code Before: <div id="sharingContainer"> <!-- <button onclick="copyText()">share link</button> --> <div class="individualShare" id='{{page.title}}' onclick="copyText()"> Share Link </div> <a href="https://twitter.com/share" class="twitter-share-button" data-url="{site.baseurl}}/{{page.url}}?redirect=1" data-via="IFPRI" data-count="none" target="_blank"></a> <!-- <div class="g-plus" data-action="share" data-annotation="none"></div> --> <!-- <div class="fb-share-button" data-href="{{site.baseurl}}{{page.url}}" data-type="button"></div> --> <div class="fb-share-button" data-href="{{site.baseurl}}/{{page.url}}?redirect=1" data-type="button"></div> <div class="panel panel-default"> <div id="panel-body" class="panel-body"> </div> </div> </div> ## Instruction: Edit data-url to twitter button1 ## Code After: <div id="sharingContainer"> <!-- <button onclick="copyText()">share link</button> --> <div class="individualShare" id='{{page.title}}' onclick="copyText()"> Share Link </div> <a href="https://twitter.com/share" class="twitter-share-button" url="{site.baseurl}}/{{page.url}}?redirect=1" data-via="IFPRI" data-count="none" target="_blank"></a> <!-- <div class="g-plus" data-action="share" data-annotation="none"></div> --> <!-- <div class="fb-share-button" data-href="{{site.baseurl}}{{page.url}}" data-type="button"></div> --> <div class="fb-share-button" data-href="{{site.baseurl}}/{{page.url}}?redirect=1" data-type="button"></div> <div class="panel panel-default"> <div id="panel-body" class="panel-body"> </div> </div> </div>