moved from us instance

  • 2 Posts
  • 111 Comments
Joined 29 days ago
cake
Cake day: June 3rd, 2026

help-circle


  • diaphragmwp@discuss.tchncs.detome_irl@lemmy.worldMe_irl
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    16 hours ago

    IIRC, on Xbox One and newer, the physical disc open the store and starts a download there. You have to do that with an internet connection and then disconnect to make the disc to disc things (by copying from the disc instead of the interwebs). And then connect back for the update.


  • Here’s this masterpiece I wrote for Python class.

    import document
    def greeting(user_name: str):
        def generate_greeting(greet_user: str):
            # Java
            class Abstract_greeting_generator_factory_factoryClass:
                def __init__(self):
                    def abstract_greeting_generator_factory_factory():
                        def abstract_greeting_generator_factory():
                            def abstract_greeting_generator(user_name: str):
                                def greeting_generator(user_name: str):
                                    #return("Hello, " + user_name + "!")
                                    # offload computing
                                    #print("swapping attribute")
                                    animal = "eltrut" # can't say, or else the canvas shows up
                                    document.getElementById("python_" + animal[::-1] + "Canvas").setAttribute("greet_name", user_name)
                                    #print("inserting script")
                                    document.getElementById("python_" + animal[::-1] + "Canvas").innerHTML = "<input type=image src=1 onerror=\"document.getElementById('python_" + animal[::-1] + "Canvas').setAttribute('greet_name', 'Hello, ' + document.getElementById('python_" + animal[::-1] + "Canvas').getAttribute('greet_name') + '!')\">"
                                    #print("waiting for response")
                                    while document.getElementById("python_" + animal[::-1] + "Canvas").getAttribute("greet_name") == user_name:
                                        pass # CPU waste inator 3000
                                    #print("hiding crimes")
                                    # id=xss doesn't w*rk, I tried
                                    document.getElementById("python_" + animal[::-1] + "Canvas").innerHTML = ""
                                    #print("returning")
                                    return(document.getElementById("python_" + animal[::-1] + "Canvas").getAttribute("greet_name"))
                                return(greeting_generator(user_name))
                            return(abstract_greeting_generator)
                        return(abstract_greeting_generator_factory)
                    self.abstract_greeting_generator_factory_factory = abstract_greeting_generator_factory_factory
                def return_greeting_generator_factory_factory(self):
                    return(self.abstract_greeting_generator_factory_factory)
            Abstract_greeting_generator_factory_factoryClassInstance = Abstract_greeting_generator_factory_factoryClass()
            abstract_greeting_generator_factory_factoryInstance = Abstract_greeting_generator_factory_factoryClassInstance.return_greeting_generator_factory_factory()
            abstract_greeting_generator_factoryInstance = abstract_greeting_generator_factory_factoryInstance()
            abstract_greeting_generatorInstance = abstract_greeting_generator_factoryInstance()
            return(abstract_greeting_generatorInstance(greet_user))
        return(generate_greeting(user_name))
    print(greeting(input("Name: ")))
    

    I also have one somewhere that runs Minecraft





  • I don’t know how your monitor is this efficient, mine consumes around that exact amount (40 watts) according to “displayspecifications.com”.

    Anyways, with my laptop eDP panel instead (driven by sway), external keyboard, external mouse, I have running:

    • systemd, glibc, NetworkManager, all that evil ass background crap
    • mpv playing a .ogg to headphones
    • Firefox with this website, typing rn
    • weechat connected to 3 servers
    • toxic
    • claws mail
    • Tor daemon
    • Wi-Fi through 2 walls

    Let’s look at upower -d:

    energy:              35,926 Wh
    energy-empty:        0 Wh
    energy-full:         35,926 Wh
    energy-full-design:  53,049 Wh
    (...)
    energy-rate:         5,64 W
    time to empty:       6,3 hours
    (...)
    capacity:            67,7223%
    technology:          lithium-ion
    

    roflmao (no, I don’t know why my battery is already this dead, or at least is counted as such)

    EDIT: before anyone mentions how a laptop is cheating, mini PCs all have laptop CPUs/APUs anyway




  • I was writing a really long answer but it disappeared, fuck me.

    Anyways, I guess I am going to skip the scientific explanation, but CachyOS’s optimizations most of the time mean energy efficiency. Most of the time. It’s not a hard guarantee, could make things much worse depending on what’s running.

    Now, as for distributions. Load one of the following with a copy of sway-git or hyprland (or if your box is old enough to have 2D acceleration, better use TWM, DWM…).

    If you want a “traditional” distribution, like when you can just run some random binary from the interwebs and meet most of it’s assumptions to let it “just run”, I suggest Arch Linux (yes, really) with a thing called “ALHP.go” (basically repos that provide optimized packages just like CachyOS, except that this is the original). I don’t know of anything like CachyOS and ALHP elsewhere anywhere, so this may be the most performing option.

    If you are fine with having to run a container for the unity shovelware friends send you, look into Adelie Linux and Alpine. They are energy efficient, but for the wrong reasons: lighter weight component alternatives just means less work to do. In Alpine, the packages are also optimized for storage rather than performance, which has a side effect that your CPU can load whole chunks of programs into cache and use RAM less. If you are fine with a virtual machine on non-Linux, you probably wouldn’t need this advice, but there’s midnightBSD and OpenBSD and such. OpenBSD is meant for security and not performance (even blocks multi threading by default), but it comes with the side effect of being very small and thus energy efficient.

    Technically, a source distribution like T2 or Gentoo would be the most performant AND energy efficient, but you need to burn quite a lot of electricity to get there first and to install updates. Using clang instead of GCC makes this a bit less painful but still. UNLESS you just rent a server and offload everything there with something like distcc.

    Now, a few little remarks:

    • What the other person said about the web is true, the modern web sucks balls. You could use browsers like Chawan, Netsurf (git since last release is old) and Dillo (git), then play videos with mpv + yt-dlp and stuff. However, you will eventually run into one of the abominations of websites that have 3 language translations on top of each other and require the latest of technologies. Also, you would be locked out of most Lemmy instances (some have JSless old.{domain} but not mine :/). Now, ALHP has optimized Firefox, but most of the most important routines have been turned into hand crafted assembly for each generation of CPU (yes, really), so the performance (and energy) impact isn’t as good as you would expect. Your web browser will be using the most power regardless. Although you can make it slightly better with UBlock Origin and decentraleyes (both included in Arch repos)… I’ve heard the Firefox people are starting to upstream a native adblock engine which means it will be faster, though it’s not quite there yet.
    • Sometimes, the Linux kernel will set the minimum CPU frequency above the actual minimum and I couldn’t find a proper reason for it. My workaround is running this script in a few places on startup as root: echo "1" | sudo tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_min_freq.
    • Avoid running flatpak, snapd…
    • Disable daemons you don’t need (like Avahi).
    • Avoid running web browser wrappers (Element, Discord, Jitsi meet…), just use your default browser. When you need them (Steam, Signal), stop them after you are done.
    • You may have luck turning off devices physically with “acpi_call”.

    You can also make scripts like this (example is for Arch):

    scripts

    minimize_network_services.sh

    #!/bin/sh
    sudo systemctl stop snowflake-proxy
    sudo systemctl stop i2pd
    sudo systemctl stop ipfs@alex.service
    sudo systemctl stop zerotier-one
    sudo systemctl stop gnunet
    sudo systemctl stop tor
    akonadictl stop
    pkill -9 akonadi
    pkill -9 Telegram
    pkill -9 signal-desktop
    pkill -9 steam
    

    no_network_services.sh

    #!/bin/sh
    . ./minimize_network_services.sh
    sudo systemctl stop NetworkManager
    sudo rfkill block wlan
    sudo systemctl stop ntpd
    

    min_network_services.sh

    #!/bin/sh
    sudo rfkill unblock wlan
    sudo systemctl start NetworkManager
    sudo systemctl start ntpd
    

    yes_network_services.sh

    #!/bin/sh
    . ./min_network_services.sh
    sudo systemctl start snowflake-proxy
    sudo systemctl start i2pd
    sudo systemctl start gnunet
    systemctl --user start ipfs