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
import sys | |
from selenium import webdriver | |
from selenium.webdriver.edge.options import Options | |
from selenium.webdriver.common.keys import Keys | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.support.ui import WebDriverWait | |
from selenium.webdriver.support import expected_conditions as EC | |
from bs4 import BeautifulSoup | |
def perform_scraping(command): |
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
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use WWW::Mechanize; | |
use HTML::TreeBuilder; | |
my $url = 'https://www.gnu.org/software/software.html'; | |
my $mech = WWW::Mechanize->new(); |
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
$destino = "$env:USERPROFILE\Pictures\Wallpapers" | |
if (-not (Test-Path $destino)) { | |
New-Item -ItemType Directory -Path $destino | Out-Null | |
} | |
$arquivos = Get-ChildItem -Path $PWD -File -Recurse | Where-Object { $_.Extension -match "png|jpg" } | |
foreach ($arquivo in $arquivos) { | |
Move-Item -Path $arquivo.FullName -Destination $destino -Force |
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
#!/bin/zsh | |
if [[ $# -eq 0 ]]; then | |
echo "Por favor, forneça um arquivo de texto como argumento." | |
exit 1 | |
fi | |
file_content=$(<"$1") | |
file_content=${file_content//$'\n'/ } |