6
submitted 2 days ago by [email protected] to c/[email protected]

Hoe do you self host a nix package repo & install nix packages from 3rd party repos? Is this even possible.

Other package managers allow you to install packages from 3rd party repos such as Flatpaks, apt, F-Droid, Scoop, Winget.

And is there any known 3rd party nix package repos?

6
submitted 2 days ago by [email protected] to c/[email protected]

When I use the --sourcemap argument in the CLI to generate the CSS builds with sourcemaps, when the CSS uses @include, it does not update the path and therefore will not work.

In the code below, the builds are stored in the dist directory, while the CSS source code is stored in the src directory.

This is my simple code to reproduce this...

- src/
   - stylesheet.css
- dist
   - my-package.css
   - my-package.css.map
- demo.html
- bundle.css
- package.json

bundle.css

@import 'src/stylesheet.css';

demo.html

<link rel="stylesheet" href="dist/my-package.css">

package.json

{
  "name": "my-package",
  "version": "1.0.0",
  "license": "MIT",
  "scripts": {
   "build": "lightningcss --sourcemap bundle.css -o dist/my-package.css"
  },
  "devDependencies": {
    "lightningcss-cli": "^1.25.1"
  }
}

src/stylesheet.css

body {
	background-color: red;
}

dist/my-package.css output

@import "src/stylesheet.css";

/*# sourceMappingURL=dist/my-package.css.map */

What I expected from the dist/my-package.css output

@import "../src/stylesheet.css";

/*# sourceMappingURL=dist/my-package.css.map */

Does anyone know why this is the outcome? Any help will be most appreciated.

0
submitted 4 days ago by [email protected] to c/[email protected]

To add the following settings for the user in their account settings...

  • Disable User From Posting
  • Disable User From Commenting
  • Disable User From Upvoting/Downvoting

Useful setting to enable for users who have two accounts. One account for browsing their feed while another account is used for interacting. These setting will prevent the user from accidently making a post with the wrong account for example

0
submitted 4 days ago by [email protected] to c/[email protected]

To add the following settings for the user in their account settings...

  • Disable User From Posting
  • Disable User From Commenting
  • Disable User From Upvoting/Downvoting

Useful setting to enable for users who have two accounts. One account for browsing their feed while another account is used for interacting. These setting will prevent the user from accidently making a post with the wrong account for example

6
submitted 5 days ago by [email protected] to c/[email protected]

Here is how you can add a simple action to open a folder in VSCodium within Nemo file manager.

  1. Create a new file in ~/.local/share/nemo/actions/ and name the file vscodium.nemo_action
  2. Open the file in a text editor
  3. Copy the code below into the file
[Nemo Action]
Name=Open in VSCodium
Comment=Open VSCodium in the selected folder
Exec=codium "%F"
Icon-Name=vscodium
Selection=Any
Extensions=dir;
  1. Save the changes made to the file
  2. Now when you right click inside a folder in Nemo, it will show an option "Open in VSCodium" and when you click this option, it will launch VSCodium using the currently directory as the workspace.

This can be modified to work with Visual Studio Code (Which is closed source unlike VSCodium) by editing codium "%F" to code "%F"

6
submitted 5 days ago by [email protected] to c/[email protected]

Here is how you can add a simple action to open a folder in VSCodium within Nemo file manager.

  1. Create a new file in ~/.local/share/nemo/actions/ and name the file vscodium.nemo_action
  2. Open the file in a text editor
  3. Copy the code below into the file
[Nemo Action]
Name=Open in VSCodium
Comment=Open VSCodium in the selected folder
Exec=codium "%F"
Icon-Name=vscodium
Selection=Any
Extensions=dir;
  1. Save the changes made to the file
  2. Now when you right click inside a folder in Nemo, it will show an option "Open in VSCodium" and when you click this option, it will launch VSCodium using the currently directory as the workspace.

This can be modified to work with Visual Studio Code (Which is closed source unlike VSCodium) by editing codium "%F" to code "%F"

[-] [email protected] 1 points 5 days ago
[-] [email protected] 1 points 5 days ago

Thank you Thunder devs for adding this feature fully into Thunder!

[-] [email protected] 3 points 1 month ago* (last edited 1 month ago)

I think stablecoins will always have a centralized point of failure. Weather it is an algorithm, or having the coin backed by the actual asset.

I think the best stablecoins are backed by the asset 1 to 1 or a little more then 1 to 1. Most stablecoins that do this are token on smart chain contracts which have another vulnerability which is being a smart contract. Smart contracts could contain a vulnerability and if it does have a vulnerability, a new contract will need to be made and users will have to switch their old token to the new tokens. Also censorship is an issue. https://cryptonews.com/news/tether-takes-action-blacklists-validator-address-linked-25-million-mev-bot-drain-heres-what-happened.htm

And these stablecoins are not private. The only private stablecoin platform out there is Haven but Haven assets are not backed 1 to 1.

I hope there are plently of stablecoins issued on Zano in the future. Zano allows you to create an asset without creating a smart contract. All assets on Zano are private. I would like to see Tether, USDC and other issue stablecoins on Zano. Trusting the issuers on backing the stablecoin and trusting the issuer to secure their private keys to prevent hackers from inflating the asset will be the only vulnerabilities, but you will have privacy and a censorship resistant stablecoin!

[-] [email protected] 2 points 2 months ago

If the AgoraDesk source code is released? Maybe? It can help anyone who wants to create a P2P trading platform. I think Haveno is written in Java and I have a hunch that AgoraDesk back end is not in Java.

[-] [email protected] 2 points 2 months ago

https://github.com/AgoraDesk-LocalMonero/agoradesk-app-foss/issues/296

I hope AgoraDesk/LocalMonero will release all of their source code for their platform after they shutdown to allow anyone to fork it and start their own platform without having to build a platform and app from scratch

[-] [email protected] 6 points 2 months ago

https://github.com/AgoraDesk-LocalMonero/agoradesk-app-foss/issues/296

Please upvote this issue if you want to see all the source code for AgoraDesk/LocalMonero be released!

20
submitted 2 months ago by [email protected] to c/[email protected]

AgoraDesk/LocalMonero is shutting down 😞

Their app is fully open source and is a slick app written in Flutter.

Upvote this request on their github if you show interest in AgoraDesk/LocalMonero in releasing all of their source code for the back end as well. It is a long shot but if AgoraDesk/LocalMonero is going to shutdown, maybe they will release their source code to allow someone else to launch a new P2P trading platform that is a fork of AgoraDesk/LocalMonero and can do so with less work.

[-] [email protected] 2 points 2 months ago

Why could a build take 5 minutes? Is it due to the size of your project or the language the bundler is written in (JavaScript being a slower option over Rust)?

11
Do we need Live Reload (Watch) in bundlers? (marketplace.visualstudio.com)
submitted 2 months ago by [email protected] to c/[email protected]

Do we need live reload feature in bunders? Couldn't we just use this extension for Visual Studio Code or simular features and extensions in other IDEs which will execute a custom command of your choice when you save a file with a certain file extension in your IDE?

https://marketplace.visualstudio.com/items?itemName=emeraldwalk.RunOnSave

This extensions allows you to customize the commands to execute in saving a file in your global VSCode settings and in the VSCode workspace settings .vscode/settings.json, allowing others to use the same configuration in group projects.

Lightning CSS does not have a live reload feature and the live reload feature in Rollup cannot handle watching many files, however using this extension in VSCode, will not watch files but run the npm run dev:css or npm run dev:js command when saving a css or js file without watching for files to change.

One downside I see with this is when working on a project with others who are using different IDEs that do not support this feature. Besides that, is there any downsides to this approach?

12
submitted 2 months ago by [email protected] to c/[email protected]

I have an active Windows 10 key on my system with Windows 10 installed and I keep getting prompt on startup to upgrade to Windows 11.

I have ignored these upgrades since I am not sure if I decided to upgrade to Windows 11, will my Windows 10 key no longer work for Windows 10 installation and only work for Windows 11 installations going forward once I upgrade?

[-] [email protected] 1 points 2 months ago

I fiddle around with podman some more and found that changing these two things will make debugging work with podman. However this will force the container to use the host network and therefore the container will not get its own network space.

Not sure if this is a good way to go about it for a PHP development environment or if there is a better way to achieve this. The problem with docker setup in the original post compared to podman is when using those steps for podman, the debugger cannot connect to the IDE (VSCode) since the podman container network is isolated as its own network.

If anyone else knows of a better way to go about this, please do share

Terminal command to create container

podman container create --name my-container -v ./app/:/usr/src/app/ -v .:/usr/local/etc/php/ -w /usr/src/app/ --network=host -it my-php-image

php.ini

xdebug.client_host = "host.containers.internal"
0
submitted 3 months ago by [email protected] to c/[email protected]

I am unable to get the VSCode debugger to work with PHP running in a podman container. I was able to set this up using Docker by following these steps...

  1. Create php.dockerfile (Dockerfile)
  2. Create php.ini
  3. Add VSCode debugging launch configuration to VSCode settings.json
  4. Create container in Docker
  5. Start container
  6. Open workspace folder of the PHP script in VSCode
  7. Add breakpoints in the PHP script in VSCode
  8. Start Debugger in VSCode
  9. Run PHP script in docker container which will trigger the debugger in VSCode

I believe it is due to some networking setup with Podman which requires additional configuring for the debugger attach itself to the PHP script in the Podman container.

Any help will be most appreciated.

Dockerfile php.dockerfile

FROM docker.io/php:cli

# Install xdebug for nicer error messages
RUN pecl install xdebug
RUN docker-php-ext-enable xdebug

php.ini

[PHP]

; xdebug settings for debugging
zend_extension=xdebug
xdebug.mode=debug
xdebug.client_host=xdebug://gateway

VSCode debugger launch config...

"launch": {
        "configurations": [
            {
                "name": "PHP (Container): Terminal",
                "type": "php",
                "request": "launch",
                "pathMappings": {
                    "/usr/src/app/": "${workspaceFolder}"
                }
            }
        ]
    },

Terminal commands to set this all up and run the script

$ docker image build -t my-php-image -f php.dockerfile .
$ docker container create --name my-container -v ./app/:/usr/src/app/ -v .:/usr/local/etc/php/ -w /usr/src/app/ -it my-php-image
$ docker container start my-container
$ docker container exec -it my-container php -d xdebug.start_with_request=yes test.php
[-] [email protected] 1 points 3 months ago

The explore feature for the local instance has been made!!!

Please add the explore feature to explore the entire fediverse!

14
submitted 3 months ago by [email protected] to c/[email protected]

Is there an easy way to enable a inactivity timer when using a TTY like in Ubuntu Server for when there has been no inactivity for X seconds, it will execute vlock and lock the TTY.

11
submitted 3 months ago by [email protected] to c/[email protected]

Lets say I have a simple JS library. Most of the JS code is inside an object named after the library with the properties being the method functions. Some of these method functions require other method functions (Example, methodC() requires methodA()).

const myLibrary = {
   methodA: function() {...},
   methodB: functiom() {...},
   methodC: function() {...},
   methodD: function() {...}
}

How would I split these methods up into modules and split up this code into multiple files to make it a standard file structure for a NPM package. Currently all of the code is in one large JS file, and it could be broken down into modules. I would like to keep it all in the one object myLibrary like most NPM packages which when used, have the following syntax...

myLibrary.methodB(true, true);

Were all the methods are contained inside a object.

Any help will be most appreciated.

[-] [email protected] 1 points 3 months ago

Changing Type=oneshot and adding RemainAfterExit=yes underneath does not allow me to boot into my system. I get this as the last terminal message

[ OK ] Reached target Cloud-init target.

No biggie to fix since I did this in a Virtual machine and could restore to an older snapshot.

[-] [email protected] 1 points 4 months ago

I do use dropbear-initramfs. However the issue if I power off or the power goes out while I am unlocking the computer, I will be unable to reboot the computer using WOL. Is there something like dropbear-initramfs but instead of it being a SSH server for the LUKS lockscreen, it is a WOL enabler?

[-] [email protected] 1 points 4 months ago

Not a bad idea as long all nodes will allow any wallet to recover all funds, not all transaction history, just balance.

view more: next ›

trymeout

joined 1 year ago