This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Security audit | |
on: | |
push: | |
paths: | |
- '**/Cargo.toml' | |
- '**/Cargo.lock' | |
jobs: | |
security_audit: | |
runs-on: ubuntu-latest | |
steps: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
*Submitted for verification at Etherscan.io on 2021-09-05 | |
*/ | |
// SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.0; | |
/// [MIT License] | |
/// @title Base64 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use PhpCsFixer\Config; | |
use PhpCsFixer\Finder; | |
$rules = [ | |
'array_syntax' => ['syntax' => 'short'], | |
'binary_operator_spaces' => [ | |
'default' => 'single_space', | |
'operators' => ['=>' => null] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//--------------- | |
// First approach | |
//--------------- | |
class Controller extends Component { | |
//..methods and props | |
render( | |
return <Presentation {...API} /> | |
) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Deployer; | |
require 'recipe/laravel.php'; | |
// Project name | |
set('application', 'trackandraces'); | |
// Project repository | |
set('repository', 'git@github.com:darthzyklus/trackandraces.git'); | |
// [Optional] Allocate tty for git clone. Default value is false. | |
set('git_tty', true); | |
// Shared files/dirs between deploys |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const areYouPlayingBanjo = (name) => ( | |
`${name} ${( (/^r/i).test(name) ? "plays" : "does not play" )} banjo` | |
); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const isValidWalk = walk => ( | |
walk.length == 10 | |
&& walk.filter(step => step == 'n').length == walk.filter(step => step == 's').length | |
&& walk.filter(step => step == 'w').length == walk.filter(step => step == 'e').length | |
); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function solution(input, markers) { | |
const comments = new RegExp(`[${markers.join("")}].+`, "g"); | |
const whiteSpaceAtTheEnd = /(\s+(?=\n))|(\s+$)/g; | |
return input.replace(comments, "").replace(whiteSpaceAtTheEnd, ""); | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function elevator(left, right, call){ | |
if (left == right) return "right"; | |
var leftDistance = Math.abs(call - left); | |
var rightDistance = Math.abs(call - right); | |
return leftDistance < rightDistance ? "left":"right"; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function containAllRots(strng, arr) { | |
var letters = strng.split(""); | |
for (var i = 0; i < strng.length; i++) { | |
if ( !arr.includes(letters.join("")) ) return false; | |
letters.unshift(letters.pop()); | |
} |
NewerOlder