Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Activity for matthewsnyderâ€
Type | On... | Excerpt | Status | Date |
---|---|---|---|---|
Suggested Edit | Post #290317 |
Suggested edit: More reflective of the self-answer (more) |
helpful | 6 months ago |
Edit | Post #290084 |
Post edited: |
— | 7 months ago |
Suggested Edit | Post #290084 |
Suggested edit: (more) |
helpful | 7 months ago |
Edit | Post #290050 | Initial revision | — | 7 months ago |
Question | — |
Get list of all variables from Jinja template Suppose you have a jinja template like this: ```lang-none I am going to {{ foo }} to get some {{ bar }}. I hope I can find: {% for i in baz %} - {{i}} {% endfor %} ``` This template will require you to pass variables `foo`, `bar` and `baz` when rendering it. If any are missing, it will ret... (more) |
— | 7 months ago |
Comment | Post #290043 |
There's several questions here:
1. How to make hotkeys run a bash command in Ubuntu?
2. How to make keybindings still work with Ubuntu in Hyper-V?
3. Workarounds for setting keyboard layout.
I think you might get better answers if you ask each one separately. Also, as the other comment says, ... (more) |
— | 7 months ago |
Comment | Post #290007 |
I agree with both points in this. In particular, SO sometimes permits a very narrow range of discussion about "best" if you lock the criteria down very tightly. But to provide comprehensive evaluation criteria, you have to be pretty expert to begin with. When you get a total noob asking things like "... (more) |
— | 7 months ago |
Edit | Post #290001 | Initial revision | — | 7 months ago |
Answer | — |
A: What software architecture are available for developing an application with multiple business domains that only share some common aspects? If I ignore the example and answer the title generally: You would put the common logic into a third piece of software that becomes the dependency of both domains. For example, let's say you are writing software for a company that has two domains of business: They sell construction tools and materi... (more) |
— | 7 months ago |
Comment | Post #289948 |
I think the question uses "program" in the sense of "service product offered to humans", not "piece of software". It also sounds like a lot of the question is about databases (I know there's parts that mention apps as potential solutions).
This makes it a bit confusing which type of "program" you'... (more) |
— | 7 months ago |
Comment | Post #289891 |
How am I going to `mv` or `cat` the stuff that comes out of that? (more) |
— | 7 months ago |
Comment | Post #289985 |
True. But remember I am proposing that instead of answers like "you have a typo in line 4", we should favor answers like "here is how you can find that a typo caused your bug...".
Anyway, why the preoccupation with typos? There is a lot more to debugging than finding typos. (more) |
— | 7 months ago |
Edit | Post #289985 |
Post edited: |
— | 7 months ago |
Comment | Post #289985 |
Like many here, most of my experience with QA sites indeed comes from SO.
I know it is not against the rules here per se. However, I have often observed people in meta discussions to suggest various types of "overly localized" questions are undesirable. There does not seem to be much gained by pro... (more) |
— | 7 months ago |
Edit | Post #289985 | Initial revision | — | 7 months ago |
Question | — |
Suggested special feature: Clinic/case study We have special features/sections on Codidact, so maybe this is a nice use for them. What if we had a section named something like "clinic" or "case study" or "debugging"? (name suggestions welcome) The point of this section would be specific debugging or troubleshooting help questions. The for... (more) |
— | 7 months ago |
Edit | Post #289914 | Initial revision | — | 8 months ago |
Question | — |
Can you run Python code on text in VS Code? In VS Code, is it possible to run Python code on the text being edited? I realize that I can save my text, create a `.py` file, switch to a terminal (including VS Code's own terminal) and run the `.py` file. However, some other editors like Gedit support running ad-hoc Python scripts to process th... (more) |
— | 8 months ago |
Comment | Post #289909 |
I know there are standalone programs for working with regexes specifically. I am not asking for those, I want a VSC extension specifically.
Posting those programs probably **will** be useful to someone, so they should go in a separate question. However, I don't want to create yet another unanswere... (more) |
— | 8 months ago |
Edit | Post #289909 | Initial revision | — | 8 months ago |
Question | — |
Advanced Regex extension for VS Code VS Code supports regex search, but the search/replace is UI is just a tiny dialog box. It's okay if you know regex well and the expression is not complex, but when trying to apply complicated expressions the usability is not good. I often end up having to "develop" the regex in regexr.com, which mean... (more) |
— | 8 months ago |
Edit | Post #289907 |
Post edited: |
— | 8 months ago |
Edit | Post #289907 |
History hidden: Detailed history before this event is hidden because of a redaction. |
— | 8 months ago |
Edit | Post #289907 |
Post edited: |
— | 8 months ago |
Edit | Post #289907 | Initial revision | — | 8 months ago |
Question | — |
How to overwrite lines of STDOUT in Python? `print()` normally adds text to STDOUT, it does not erase existing text. https://linux.codidact.com/posts/289869 describes various ways of doing the overwrite in shell scripts. How can you do this in Python? (more) |
— | 8 months ago |
Edit | Post #289906 |
Post edited: |
— | 8 months ago |
Edit | Post #289906 | Initial revision | — | 8 months ago |
Question | — |
How to open VS code with a particular path expanded? When you do: ```sh cd /some/path code . ``` VS Code opens with that location shown in the "Explorer" sidebar. However, the state of the file tree and the currently open files will be the same as what was remembered from the last session. Let's say that last time I was editing `/some/path/fo... (more) |
— | 8 months ago |
Edit | Post #289891 | Initial revision | — | 8 months ago |
Question | — |
How to provide meaningful names for emails in Maildir? I am writing some scripts that operate on emails in Maildir format. A lot of things are easy in this format, but the filenames are absolutely incomprehensible. For example, one script moves mails between folders based on some rules. It has a dry run mode which simply says which mails would be move... (more) |
— | 8 months ago |
Edit | Post #289889 | Initial revision | — | 8 months ago |
Question | — |
Regex for simplifying Amazon product URLs Amazon product URLs are often very long, but on experimentation it is revealed that the following pattern is sufficient: ``` https://www.amazon.com/{dp|gp}/$ID ``` `ID` is a 10-char string, which I'm guessing is the ASIN. I want to parse out the long URLs into the minimal form. What exactly is ... (more) |
— | 8 months ago |
Edit | Post #289887 | Initial revision | — | 8 months ago |
Question | — |
Determine which script is slowing the page down in Firefox A page is very slow and laggy in Firefox. I am certain it's one of the many Javascripts slowing it down. Out of curiosity, I'd like to figure out which script is creating the heaviest load. Note that I also have some blocked with uBlock origin, and I don't want to unblock those - I want to see whi... (more) |
— | 8 months ago |
Edit | Post #289884 |
Post edited: |
— | 8 months ago |
Edit | Post #289884 | Initial revision | — | 8 months ago |
Answer | — |
A: Shortcut for inserting today's date in VS Code You can use snippets for this. In the example below, when you type `today` and trigger completion (usually Ctrl+Space) you will see an option to insert the date by pressing Enter. Snippet code: ```json "today ISO": { // applies everywhere "scope": "", "prefix": "today", "body": [ "$CU... (more) |
— | 8 months ago |
Edit | Post #289883 | Initial revision | — | 8 months ago |
Question | — |
Shortcut for inserting today's date in VS Code Is there a way to easily insert today's date when editing a file in VS Code? (more) |
— | 8 months ago |
Comment | Post #289860 |
This works also, and is better. It doesn't open files that were open in the previous session, which I like. (more) |
— | 8 months ago |
Edit | Post #289858 | Initial revision | — | 8 months ago |
Answer | — |
A: VS Code: How to open a file and folder in a new window? Best I could do was: ```shell cd /foo/bar && code --new-window . && code baz.txt ``` The `cd` is not necessary but makes the command cleaner. I would still like to know if there's a cleaner way. (more) |
— | 8 months ago |
Edit | Post #289857 | Initial revision | — | 8 months ago |
Question | — |
VS Code: How to open a file and folder in a new window? I've figured out that `code --new-window /foo/bar/baz.txt` will open `baz.txt` in a new window. But when I do this, it says "no folder opened" in the file explorer pane. That makes it hard to work with other files in the same directory. How can I also set the folder when opening a file like this? ... (more) |
— | 8 months ago |
Comment | Post #289828 |
I don't disagree that poorly made batteries can be dangerous, but I think that maybe an extended discussion of battery discharge related hazards can be moved to a more appropriate site, like electrical engineering, rather than a question about boolean operators in programming.
This appears to have... (more) |
— | 8 months ago |
Comment | Post #289828 |
I know, I just think you're hamming it up a little too much :)
Decades ago it might have been like you describe, but not anymore really. Especially in electronics, where you work with low voltages, it's hard to make things explode.
Battery packs these days do have intelligence with built in cir... (more) |
— | 8 months ago |
Edit | Post #289837 |
Post edited: |
— | 8 months ago |
Edit | Post #289837 |
Post edited: |
— | 8 months ago |
Edit | Post #289837 |
Post edited: |
— | 8 months ago |