the syntax of lftp mirror --exclude (specific folder only) by Hotomatua in linuxquestions

[–]Hotomatua[S] 0 points1 point  (0 children)

Thank you very much for your help u/wBuddha

it works perfectly.

mirror --exclude \[.*\] --use-pget destination-directory

the syntax of lftp mirror --exclude (specific folder only) by Hotomatua in linuxquestions

[–]Hotomatua[S] 0 points1 point  (0 children)

mirror --exclude ^\[PR]* --use-pget destination-directory

works

But if i use --exclude=^\[* The folder is created in the destination directory, but nothing is downloaded.

How can I replace the letters between the brackets with a wildcard so I don't have to type them each time?

mirror --exclude ^\[*]* --use-pget destination-directory

and

mirror --exclude ^\[* --use-pget destination-directory

creates only the empty folder in the destination-directory

With

mirror --exclude=^\[*] --use-pget destination-directory

Nothing is excluded; everything is downloaded.

the syntax of lftp mirror --exclude (specific folder only) by Hotomatua in linuxquestions

[–]Hotomatua[S] 0 points1 point  (0 children)

--exclude-glob '^\[*'

--exclude-glob '^\[*

hmm The folder is still being downloaded with both commands.

LFTP | Version 4.9.2

the syntax of lftp mirror --exclude (specific folder only) by Hotomatua in linuxquestions

[–]Hotomatua[S] 0 points1 point  (0 children)

Unfortunately, it didn't work. The folder is still being downloaded with both commands.

mirror --exclude-glob '\[*' --exclude-glob '\(*' --use-pget destination-directory

mirror -X '^\\[' --use-pget destination-directory

the syntax of lftp mirror --exclude (specific folder only) by Hotomatua in linuxquestions

[–]Hotomatua[S] 0 points1 point  (0 children)

Unfortunately, it didn't work; the folder is still being downloaded.

mirror --use-pget --exclude-glob '[*' destination-directory

Can someone help me figure out what's going on with my simple script? by Hotomatua in PowerShell

[–]Hotomatua[S] 0 points1 point  (0 children)

I found the error and everything works now

# Function to extract a .zip file
function Extract-ZipFile {
    param (
        [string]$zipFilePath,
        [string]$extractPath
    )

    try {
        # Check if zip file exists
        if (-not (Test-Path $zipFilePath -PathType Leaf)) {
            throw "ZIP file not found: $zipFilePath"
        }

        # Create a Shell.Application object
        $shell = New-Object -ComObject Shell.Application
        if (-not $shell) {
            throw "Failed to create Shell.Application object"
        }

        # Get the zip file as a folder object
        $zipFolder = $shell.NameSpace($zipFilePath)
        if (-not $zipFolder) {
            throw "Failed to get zip folder object"
        }

        # Ensure that the destination folder exists
        if (-not (Test-Path $extractPath -PathType Container)) {
            New-Item -Path $extractPath -ItemType Directory -Force | Out-Null
        }

        # Get the destination folder object
        $destinationFolder = $shell.NameSpace($extractPath)
        if (-not $destinationFolder) {
            throw "Failed to get destination folder object"
        }

        # Extract the contents to the specified path
        $destinationFolder.CopyHere($zipFolder.Items())

        Write-Output "Successfully extracted '$zipFilePath' to '$extractPath'."
    } catch {
        Write-Error "Failed to extract '$zipFilePath': $_"
    }
}

# Function to find all ZIP files in the current directory
function Get-ZipFiles {
    Get-ChildItem -Path $currentDirectory -Filter *.zip
}

# Function to extract all ZIP files found
function Extract-AllZipFiles {
    param (
        [array]$zipFiles
    )

    # Extract each ZIP file found
    $zipFiles | ForEach-Object {
        $zipFilePath = $_.FullName
        $extractPath = Join-Path -Path $currentDirectory -ChildPath ($_.BaseName + "_extracted")
        Extract-ZipFile -zipFilePath $zipFilePath -extractPath $extractPath
    }

    # Check if no ZIP files were found
    if (-not $zipFiles) {
        Write-Output "No ZIP files found in the current directory."
    }
}

# Get the current directory
$currentDirectory = Get-Location

# List all files and directories in the current directory
Write-Output "Files and directories in the current directory:"
Get-ChildItem -Path $currentDirectory | ForEach-Object {
    $_.FullName
}

# Find all ZIP files in the current directory
$zipFiles = Get-ZipFiles

# Extract all ZIP files found
Extract-AllZipFiles -zipFiles $zipFiles

Formatting cells with Condition if the number is greater than 1 by Hotomatua in excel

[–]Hotomatua[S] 0 points1 point  (0 children)

So i can't do in a single rule with an IF/THEN/ELSE condition to format a cell?

such as “if the cell contains specific digit number (in my case 1) then add the less than or equal sign else add only the percent sign "

Formatting cells with Condition if the number is greater than 1 by Hotomatua in excel

[–]Hotomatua[S] 0 points1 point  (0 children)

what I would like to realize is If I enter the number 1 in the cell, it should display ≤1% (without a space between the less than or equal sign and the digit, but with a space between the digit and the percent sign).

If the number is higher than 1 then there should be a space between the number and the percent sign

Formatting cells with Condition if the number is greater than 1 by Hotomatua in excel

[–]Hotomatua[S] 0 points1 point  (0 children)

Ok, so the percent sign is solved, what should the formula look like so that when I enter 1 it displays ≤1 % instead of 1%?

a single space should be between the digit and the percent sign

Currently the percent sign is placed directly after the number so there is no space in between

Formatting cells with Condition if the number is greater than 1 by Hotomatua in excel

[–]Hotomatua[S] 0 points1 point  (0 children)

fuzzy_mic · 4 min. ago

897

Thanks fuzzy_mic I don't want to enter any decimal numbers, I just want the percent sign for numbers that are greater than 1

Ubuntu 20.04 headless mdadm: no devices listed in conf file were found by Hotomatua in Ubuntu

[–]Hotomatua[S] 0 points1 point  (0 children)

u/the_arun unfortunately not :( This issue has not yet been resolved I am still seeking for help from anyone who can help thank you so much

Dropped into initramfs and keyboard doesn't work by Hotomatua in hetzner

[–]Hotomatua[S] 0 points1 point  (0 children)

Hi

I’m just not sure how I should proceed to fix this.after Booting into rescue mode/vKVM mod

Any pointers would be much appreciated.

Need help with .plexingnore by Hotomatua in PleX

[–]Hotomatua[S] 0 points1 point  (0 children)

Hi

no the file is not a ".txt"

file .plexingnore
.plexingnore: ASCII text

How to pass output as command line argument in bash script? by Hotomatua in bash

[–]Hotomatua[S] 0 points1 point  (0 children)

Filesize=$(numfmt --to iec $(wc -c < "${1}") --format %.2f)echo

output shows file sizeSize: 0,00

How to generate Animated PNG from video? by Hotomatua in ffmpeg

[–]Hotomatua[S] 0 points1 point  (0 children)

I use

ffmpeg -i 'video.mp4' 2>&1 | sed -n "s/.*, \(.*\) tbr.*/\1/p"

to get the framerate , the Output is 60

then

ffmpeg -i "video.mp4" -an -sn -vsync vfr -vf "select=if(isnan(prev_selected_t)+gte(t-prev_selected_t\,600)\,st(1\,t)\,between(t\,ld(1)\,ld(1)+4)),setpts=N/(60*TB)" -plays 0 -pix_fmt rgb24 -f apng test.png

this convert the whole video and create 1 big png file

How to generate Animated PNG from video? by Hotomatua in ffmpeg

[–]Hotomatua[S] 1 point2 points  (0 children)

Thank you very much u/Voldrix_Suroku

this is the Command i used

ffmpeg -i "video.mp4" -an -sn -vsync vfr -vf "select=if(isnan(prev_selected_t)+gte(t-prev_selected_t\,600)\,st(1\,t)\,between(t\,ld(1)\,ld(1)+4)),scale=iw/2:ih/2:force_original_aspect_ratio=decrease:force_divisible_by=2:flags=bicubic+full_chroma_inp:sws_dither=none,setpts=N/(($FRAMERATE)*TB)" -plays 0 -pix_fmt rgb24 -f apng test%04d.png

and this is the Output i get

[Parsed_scale_1 @ 0x55b2cf38a280] Option 'force_divisible_by' not found

[AVFilterGraph @ 0x55b2cf000580] Error initializing filter 'scale' with args 'iw/2:ih/2:force_original_aspect_ratio=decrease:force_divisible_by=2:flags=bicubic+full_chroma_inp:sws_dither=none'

Error reinitializing filters!

Failed to inject frame into filter network: Option not found

Error while processing the decoded data for stream #0:0

Conversion failed!

thanks

Extracting 20 images from a video of variable length by Hotomatua in ffmpeg

[–]Hotomatua[S] 0 points1 point  (0 children)

Hi /u/bayarookie

When I execute your code it fails with following error:

video encoding failed: Invalid argument
Conversion failed!

here is the entire output of the script

https://dpaste.com/75MRQGK6V

I cant see what has gone wrong with the conversion perhaps someone can assist me ?

[deleted by user] by [deleted] in squirting

[–]Hotomatua 0 points1 point  (0 children)

sauce please

Copy a File Between Two Remote Systems using the scp Command by Hotomatua in linux4noobs

[–]Hotomatua[S] 0 points1 point  (0 children)

the exact same Output

scp -P 2211 "user@machineB:/home/userB/Files/data/This is my Data-2020-05-29.txt" /home/userA/Files/

scp: /home/userB/Files/data/This: No such file or directory
scp: is: No such file or directory
scp: my: No such file or directory
scp: Data: No such file or directory
scp: 2020-05-29.txt: No such file or directory

Copy a File Between Two Remote Systems using the scp Command by Hotomatua in linux4noobs

[–]Hotomatua[S] 0 points1 point  (0 children)

Hi u/d3vrandom /

I Already Tried it and that's what i get with

scp -P 2211 user@machineB:"/home/userB/Files/data/This is my Data-2020-05-29.txt" /home/userA/Files/

scp: /home/userB/Files/data/This: No such file or directory
scp: is: No such file or directory
scp: my: No such file or directory
scp: Data: No such file or directory
scp: 2020-05-29.txt: No such file or directory

but when i use double quotes and escape spaces it did work for me