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 App\Controller; | |
use Symfony\Component\HttpFoundation\Response; | |
use Symfony\Component\Routing\Annotation\Route; | |
class ContatosController | |
{ | |
/** | |
* @var ExtratorDeContatoPorRequest |
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 | |
$socket = stream_socket_server("tcp://0.0.0.0:8000", $errno, $errstr); | |
if (!$socket) { | |
var_dump($errno, $errstr); | |
exit(1); | |
} | |
while ($con = stream_socket_accept($socket)) { |
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
document | |
.querySelectorAll('button[aria-label^="Aceitar o convite de"]') | |
.forEach((btn, i) => setTimeout(() => btn.click(), i + 500)); |
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
xdebug.mode=debug | |
xdebug.discover_client_host=0 | |
xdebug.client_host=host.docker.internal |
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
<mxfile host="app.diagrams.net" modified="2023-07-17T17:13:44.478Z" agent="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36" etag="5PvtiTya1RYCcQBED2bU" version="21.6.2" type="device"> | |
<diagram name="Página-1" id="mI2GYrTSxOv4K2kOxEs7"> | |
<mxGraphModel dx="1434" dy="792" grid="1" gridSize="10" guides="1" tooltips="1" connect="1" arrows="1" fold="1" page="1" pageScale="1" pageWidth="827" pageHeight="1169" math="0" shadow="0"> | |
<root> | |
<mxCell id="0" /> | |
<mxCell id="1" parent="0" /> | |
<object placeholders="1" c4Name="Avaliador" c4Type="SystemScopeBoundary" c4Application="Software System" label="<font style="font-size: 16px"><b><div style="text-align: left">%c4Name%</div></b></font><div style="text-align: left">[%c4Application%]</div>" id="qcH5OeLFRZIFURpJNsWB-1"> | |
<mxCell style="rounded=1;fontSize=11;whiteSpace=wrap;html=1;dashed=1;arc |
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 | |
use PhpImap\Mailbox; | |
require_once 'vendor/autoload.php'; | |
$mailbox = new Mailbox( | |
'{imap.gmail.com:993/imap/ssl}INBOX', | |
'seu-email@gmail.com', | |
'sua senha aqui', |
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
FROM php:8.3-cli | |
RUN apt update && apt install -y libffi-dev libz-dev libpng-dev git libzip-dev | |
RUN docker-php-ext-install ffi sockets gd pcntl zip | |
COPY --from=composer:2.5.8 /usr/bin/composer /usr/bin/composer | |
RUN composer require codewithkyrian/transformers | |
RUN ./vendor/bin/transformers install |
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 | |
$streams = [ | |
stream_socket_client('tcp://example.org:80'), | |
fopen('composer.json', 'r'), | |
fopen('package.json', 'r'), | |
]; | |
foreach ($streams as $stream) { | |
stream_set_blocking($stream, false); |