@ammdias@masto.pt
@ammdias@masto.pt avatar

ammdias

@ammdias@masto.pt

Semi-nómada solitário. Gosto de #livros, #programação, #linux, #futebol, #SportingCP e outras coisas.

This profile is from a federated server and may be incomplete. Browse more on the original instance.

ammdias, to random Portuguese
@ammdias@masto.pt avatar

Estamos em maio, mais do que tempo para o frio e a chuva se irem embora. Assim nem as cerejas amadurecem...

ammdias, to Portugal Portuguese
@ammdias@masto.pt avatar
caiocgo, to random Portuguese
@caiocgo@mastodon.social avatar

deleted_by_author

  • Loading...
  • ammdias,
    @ammdias@masto.pt avatar

    @caiocgo

    Para KDE, outra alternativa a experimentar pode ser o Tuxedo OS. É baseado em Ubuntu (por isso talvez seja melhor esperar um pouco até que seja lançada a versão baseada em Ubuntu 24.04), mas com algumas alterações. É desenvolvida especialmente para os computadores Tuxedo, mas corre em qualquer um.

    https://www.tuxedocomputers.com/en/TUXEDO-OS_1.tuxedo

    edsantos, to random Portuguese
    @edsantos@ciberlandia.pt avatar

    Nem sou muito de embirrar com problemáticas de linguagem de género, mas estava aqui a ver na TV o resumo do Lyon - Benfica para a Women's Champions League, e a pensar...

    Há qualquer coisa de errado na expressão "Liga dos Campeões Feminina". 🤨

    ammdias,
    @ammdias@masto.pt avatar

    @luis @edsantos

    Penso que a tradução mais correta seria talvez Liga dos Campeões UEFA, Sexo Feminino ou Liga dos Campeões UEFA, Mulheres. Porque nem a liga nem os clubes são femininos 🙂

    ammdias,
    @ammdias@masto.pt avatar

    @luis @edsantos

    O nome original é UEFA Women's Champions League.

    ammdias,
    @ammdias@masto.pt avatar

    @villares @luis @edsantos

    Sempre assumi que se estaria a falar de clubes (portanto, masculino) e não de equipas, apesar da palavra não estar na designação, talvez porque antes da Liga dos Campeões existiam a Taça dos Campeões Europeus e a Taça dos Clubes Vencedores das Taças (ou simplesmente Taça das Taças). É tão mais simples uma língua onde não existe género em coisas inanimadas 🙂

    vascorsd, to random
    @vascorsd@mastodon.social avatar

    These fuckers at the supermarket have the pooper paper for 18 rolls be more expensive per single roll than the exact same package with just 12 rolls.

    One usually assumes that the bigger package would have the cheaper price per unit.

    🤬

    ammdias,
    @ammdias@masto.pt avatar

    @portugalense @vascorsd

    Also, check the number of sheets per roll, as sometimes it's different in different packagings.

    caiocgo, to random
    @caiocgo@mastodon.social avatar

    deleted_by_author

  • Loading...
  • ammdias,
    @ammdias@masto.pt avatar

    @caiocgo

    This is the way Proton Drive should also be implemented in Linux.

    @protonprivacy

    villares, to python Portuguese
    @villares@ciberlandia.pt avatar

    Seems OK to me...

    with open(text_file) as f:<br></br>    items = [line for line in f.read().splitlines()<br></br>             if line.strip() and not line.startswith('#')]<br></br>
    

    Context: A txt file with a list of files to process, some are commented out, and there is a first line head comment followed by a blank line.

    ammdias,
    @ammdias@masto.pt avatar

    @villares

    f.read().splitlines() may be replaced by just f but then the newline character would be included in each line. Also, in both versions the commented lines will still be included if the # character is preceded by whitespace.

    ammdias,
    @ammdias@masto.pt avatar

    @villares

    To remove the endline character, rstrip() should be used, to preserve the whitespace at the start of the line. To check for an empty line, maybe isspace() is more efficient?

    items = [line.rstrip() for line in f if not line.isspace() and not line.lstrip().startswith('#')]

    EDIT: this assumes a comment cannot be added in the end of the line (e.g. like in Python).

    ammdias, to mastodon
    @ammdias@masto.pt avatar

    Using Firefox on my mobile phone to access Mastodon. Everything works fine with one exception: I can't find a way to read the Alt-Text of images. This is annoying 🙁

    darth, to linux
    @darth@silversword.online avatar

    deleted_by_author

  • Loading...
  • ammdias,
    @ammdias@masto.pt avatar

    @darth

    I would use rsync to syncronize the directory structure on the two computers.

    ammdias, to music
    @ammdias@masto.pt avatar

    Somebody's making good music still.

    Glad, by The Bygones:

    https://www.youtube.com/watch?v=bxzEqO8ZGsI

    chicob, to random Portuguese
    @chicob@mstdn.social avatar

    A mystery.
    Let’s say cell A1 has the number 2.

    =-1*A1^2 evaluates as -4
    =-(A1^2) evaluates as -4
    but
    =-A1^2 evaluates as 4…

    Why? I never noticed this behaviour. Was it always like this? What is wrong here? Am I going crazy?

    ammdias,
    @ammdias@masto.pt avatar

    @chicob

    I think it's due to the operation order of precedence. Minus has precedence over exponentiation and both over multiplication. So -A1 is evaluated before squaring the result, like (-A1)^2 .

    ammdias,
    @ammdias@masto.pt avatar

    @catarinac @chicob

    Maybe 😏 See the note on the Arithmetic Operators here:

    https://help.libreoffice.org/latest/lo/text/scalc/01/04060199.html

    ammdias,
    @ammdias@masto.pt avatar

    @catarinac

    In this case it's mathematicians fault, because it's ambiguous:

    -2^2 = 4

    but

    -a^2 = -4 when a=2 🤔

    @chicob

    ammdias,
    @ammdias@masto.pt avatar

    @catarinac @chicob

    So, when dealing with computers always use parenthesis if you are not completely sure of the rules of precedence on the specific program you are using.

    dgar, to random
    @dgar@aus.social avatar
    ammdias,
    @ammdias@masto.pt avatar

    @dgar

    The fact that her glass has less wine than his probably means this has happened before.

    ammdias, to random Portuguese
    @ammdias@masto.pt avatar

    A Rede Nacional de Bibliotecas Públicas está a iniciar um projeto para possibilitar o empréstimo de livros em formato digital pelas bibliotecas públicas.

    https://www.publico.pt/2023/12/30/culturaipsilon/noticia/emprestimo-livros-electronicos-bibliotecas-publicas-vai-avancar-2024-2075233

    ammdias,
    @ammdias@masto.pt avatar

    No entanto, a plataforma a implementar tem uma limitação grave:

    "A leitura só será possível na plataforma, que estará disponível para smartphones, tablets ou computadores: basta que o dispositivo esteja ligado à Internet. O serviço não poderá ser usado por ereaders (leitores de texto)."

    Ou seja, não posso ler no meu e-reader, o que impossibilita a leitura nos meus locais favoritos: praia, esplanada ou parque público.

    ammdias,
    @ammdias@masto.pt avatar

    @villares, pelo que percebi, trata-se apenas de um leitor online. Ou seja, o livro nunca está totalmente no dispositivo do utilizador nem num formato que permita ser interpretado por uma aplicação independente, dependerá sempre da plataforma a disponibilizar pela Rede de Bibliotecas.

    geo, to random
    @geo@mastodon.scot avatar

    Sitting here, masked up - recovering from my own sinus infection I’ve had all week - in the airport waiting for the flight back to Edinburgh.

    The sheer amount of people in this airport waiting area who are coughing, spluttering, and just sounding sick all while not masked … we’re doomed. No doubts about it.

    Whatever virus that wants to frolic freely through the human race - it’s free to do so. This is the world we’ve always lived in and continue to learn nothing from.

    ammdias,
    @ammdias@masto.pt avatar

    @geo

    I don't want to get sick, so I wear a mask when in closed environments with lots of people around me. But humans are very numerous, we're not doomed 😉

    ammdias,
    @ammdias@masto.pt avatar

    @geo

    It's not optimism. With such a large gene pool, it's very unlikely any virus would completely wipe out humanity, even if we don't take into account any containing measures like the ones that were used for COVID-19.

    ammdias, to python Portuguese
    @ammdias@masto.pt avatar

    Updated my editor for simple-text encrypted files.

    https://github.com/ammdias/sste/releases/tag/v0.3

    ammdias,
    @ammdias@masto.pt avatar

    Big change on SSTE: it is now possible to use GnuPG public keys to encrypt the files, allowing sharing a file with a team without also sharing a common passphrase.

    https://github.com/ammdias/sste/releases/tag/v1.0

    ammdias,
    @ammdias@masto.pt avatar

    Version 1.1.1 corrects a bug in previous versions install script that prevented correct installation and adds an uninstall option.

    https://github.com/ammdias/sste/releases/tag/v1.1.1

  • All
  • Subscribed
  • Moderated
  • Favorites
  • provamag3
  • kavyap
  • DreamBathrooms
  • everett
  • magazineikmin
  • InstantRegret
  • ngwrru68w68
  • Youngstown
  • Durango
  • slotface
  • rosin
  • GTA5RPClips
  • tester
  • PowerRangers
  • anitta
  • thenastyranch
  • mdbf
  • osvaldo12
  • ethstaker
  • vwfavf
  • cubers
  • normalnudes
  • tacticalgear
  • khanakhh
  • cisconetworking
  • modclub
  • Leos
  • megavids
  • All magazines