This file contains 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 | |
declare(strict_types=1); | |
namespace App\Share\Application\ArgumentResolver; | |
use Attribute; | |
#[Attribute(Attribute::TARGET_PARAMETER)] | |
class FromRequestBody |
This file contains 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
apt update | |
apt install ca-certificates curl gnupg lsb-release | |
mkdir -p /etc/apt/keyrings | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg | |
echo \ | |
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \ | |
$(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null | |
apt update | |
apt install docker-ce docker-ce-cli containerd.io docker-compose-plugin |
This file contains 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
extern crate rand; | |
use rand::Rng; | |
use std::cmp::Ordering; | |
use std::net::UdpSocket; | |
use std::str; | |
fn main() { | |
let server = Server { | |
socket: UdpSocket::bind("0.0.0.0:34000").expect("couldn't bind to address"), |
This file contains 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 AppBundle\Form\Extension; | |
use Symfony\Component\Form\AbstractTypeExtension; | |
use Symfony\Component\Form\FormInterface; | |
use Symfony\Component\Form\FormView; | |
use Symfony\Component\OptionsResolver\OptionsResolverInterface; | |
/** |