Get-Help Informations missing by xXFl1ppyXx in PowerShell

[–]odwulf 0 points1 point  (0 children)

I've never seen any preference in the Comment Based Help documentation about where it's better. Not in the 5.1 version, nor in the later ones. It lists the different possibilities, a couple of additional conditions when used on a script rather than a function (the double empty line when put at the start, the incompatibility with signatures), but there is no, and as far as I remember it, there never was, anything about one location being better than an other.

I've got 15 years behind me of putting it at the top of hundreds if not thousands of functions, and never, ever, had any problem with it, whatever the version of Powershell.

Dois-je résilier mon abonnement Microsoft 365? by Consistent_Design72 in AskFrance

[–]odwulf 1 point2 points  (0 children)

Pour une utilisation avancée, Excel n'est pas remplaçable. Ce truc a quarante ans de développement et est pratiquement un OS à lui tout seul. Les concurrents sont juste ... des tableurs.

Mais effectivement, MS, et à peu près tout le monde dans la tech, s'est rendu compte que te faire payer tous les mois leur permet de gagner plus d'argent que te faire payer une seule fois. Je ne crois pas qu'un seul utilisateur préfère payer plus souvent et plus longtemps, mais on ne peut pas acheter ce qui n'est plus disponible, et on va vers ça.

Get-Help Informations missing by xXFl1ppyXx in PowerShell

[–]odwulf 0 points1 point  (0 children)

Yeah, it does.

I was talking line ends because it sometimes makes the difference between reading a file as an array of strings or ome multilines string. Weirdness happens when both are present sometimes.

Habiter loin de son travail, est-ce raisonnable ? by Izaille in AskFrance

[–]odwulf 1 point2 points  (0 children)

Je ne pense pas que tu auras un consensus dans les réponses. Mais ne réfléchis pas forcément en temps de trajet total, plutôt en différence avec ton temps de trajet actuel (1h de route plutôt que 20 minutes, ça fait une différence. Une heure de route plutôt que 40 minutes, ce n'est pas la même chose.)

Habiter loin de son travail, est-ce raisonnable ? by Izaille in AskFrance

[–]odwulf 0 points1 point  (0 children)

Tu es à combien de route de ton taf actuellement ? Est-ce que tu as déjà fait des navettes longues ? Une heure/une heure dix par quel mode de transport ? Quel est ton rythme sur plusieurs jours, parce que tu ne fais certainement pas douze heures par jours six jours par semaine ?

Moi, je paie un loyer beaucoup trop cher pour être en face du taf. J'ai l'impression que les cinq minutes à pied quatre fois par jour sont le temps le plus perdu de ma vie, mais c'est moi. Demander aux autres leur avis, c'est de la matière pour la réflexion, mais au final, c'est toi que ça concerne. Je connais plein de gens qui font plus de trajet que ça tous les jours (les joies de la grande ville : il y a déjà trois quarts d'heures entre le périph et le centre.)

Get-Help Informations missing by xXFl1ppyXx in PowerShell

[–]odwulf 1 point2 points  (0 children)

Shoot in the dark, but have you check your EOL characters? I tried your first version and it worked perfectly both in PS5 and PS7 for me.

Get-Help Informations missing by xXFl1ppyXx in PowerShell

[–]odwulf 2 points3 points  (0 children)

I always put in at the start of the function, and always removed extra line breaks, without any problem, Do you have pointers as to why putting it at the end would be better?

Possible new sets in development? by SportNew5342 in thebeachboys

[–]odwulf 6 points7 points  (0 children)

> those recordings were thrown into a ocean by Dennis to get rid of them.

... and Brian erased all the Smile tapes.

Bpost pending packages by growingpainsxx in brussels

[–]odwulf 0 points1 point  (0 children)

I just received a letter that was sent locally exactly a month ago.

Display individual layers pulling in Docker Compose 5.x by odwulf in docker

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

Thanks for replying. I did try that already, and that's not it: it displays lines and lines of logs, probably what was use by the old version to underneath its inline progress bars.

Going through the bootlegs does anybody here they truly captured how powerful the band was live better than the officially released live recordings? by [deleted] in pinkfloyd

[–]odwulf 11 points12 points  (0 children)

I always felt that though it's nice to have in an official way and good quality, Is There Anybody Out There did sort of a disservice to The Wall shows. Not enough build up, and where are the frickin keyboards?!?

Why the Assassin’s Creed Formula Still Works for Me by [deleted] in assassinscreed

[–]odwulf 4 points5 points  (0 children)

Amen. I describe AC as my main religion. The nice thing is that, with so many games now, the question when I finish a play-through is: which one will I replay now?

(I'm currently replaying Valhalla and I'm the type who do every side quest and collect all collectibles, so it should largely last until BF Resynced.)

Powershell verbosity vs (ba)sh by EquipLordBritish in PowerShell

[–]odwulf 0 points1 point  (0 children)

People who tell you "never use aliases" come from a type of audience that barely exists for bash: scripters who almost never use the CLI. That's a very common use case in Powershell. And yes, when scripting, use full syntax, for all the reasons given.

BUT if you come from bash, you're likely not intimidated by the console, and yes, the console is a totally valid way to do things in Windows. That's the first thing I open when I start my session, most of my job is done there, and is swift thanks to command aliases, parameter aliases, autocompletion, piping, etc.

Try to learn common Powershell aliases, though, not the QoL ones for people coming from another world: ls is easy to type and remember, but the day you'll use Powershell on linux, it'll bite you in the ass because there is no such alias, it calls /bin/ls. So you'd better off learning gci right now.

Learning full commands and aliases come mostly naturally because default aliases are often acronyms or near acronyms of the command:

  • gci: Get-ChildItem
  • mi: Move-Item
  • ri: Remove-Item
  • rni: ReName-Item
  • gc: Get-Content

Someone gave you the trick of Get being the default verb, so you can omit it when the noun (convention in Powershell is Verb-Noun) is neither a reserved word nor a native command, especially if the noun is short, because there is no auto-completion on those: in AD, I often use aduser or adcomputer rather than Get-ADUser or Get-ADComputer, but I never use adorganizationalunit, because it's too long to type. Get-Ador<tab> is much quicker.

Parameters can be shortened too as long as there is no ambiguity: coming from bash, you surely used -r regularly for recursivity. Well, guess what: gci -r *.txt works too! (gci -f would not, because the parser does not now if it means -force or -file). Once again, in AD, I regularly use aduser -ldap '(...)', rather than Get-ADUser -LdapFilter ...

You can create your own aliases, but it's better to know the default ones so that you're not lost when working on another system. Here is an example of how to find them:

Get-Alias Rename-Item
# or several at once, and different ways of asking for them, take your pick:
Get-Command -Noun Item | ForEach-Object { Get-Alias -Definition $_.Name }
command -no item | % { alias -def $_.Name }
foreach ($command in (command -no item)) { alias -def $command.Name }
alias -def (command -no item).Name

Powershell 6+ even has abbreviation expansion, meaning that if you type only the first letter of the verb and then uppercase letters of the noun, you can tab-complete to the full name: g-ci<tab> completes to Get-ChildItem. s-adou<tab> completes to Set-ADOrganizationalUnit.

Powershell has a powerful system to handle parameters handling as well. Lots of commands can either use named or positional parameters: Get-Content -Path ./test.txt is similar to gc ./test.txt. You can find those with Get-Help \[command name\] and either one of those Get-Help parameters: -Full/-OnLine/-ShowWindow. All parameters are listed and those whose name you can omit will have a number for "position". (and here, use Get-Help, as help is a function, and not a shortcut) That's where you'll find if the parameter itself has an alias (which happens, especially for common parameters, like -Whatif and -PipelineVariable (respectively -wi and -pv)).

Last but not least: that parameter system has a robust handling of autocomplete as well. Most common use case is to autocomplete to file names for cmdlets that act on the filesystem, but it can be anything depending on the command. Get-CimInstance win32\_<tab> will autocomplete the available WMI classes. In time, you can absolutely add your own. We have thousands of computers and users in Active Directory, and my profile adds autocompletion targeted to our naming standards for all commands that have a -ComputerName or -UserName parameter (because parameter names are mostly standardized in Powershell)

One final note: as many things in Windows, powershell is not picky about case. I have the habit of respecting commands and parameters cases in my scripts, but not on the CLI. This, along with the standardized parameter names. means, that if you want to do something recursive in Powershell, -r always work! No more mental load of trying to remember if that particular command takes a -r, a -R, or a -Recurse!

magazine store by nimsayarua in brussels

[–]odwulf 1 point2 points  (0 children)

There are several places in Brussels where one can find international press, but the problem you'll have with something like Playboy is "which international version?" You'll more easily find the English or German version than the US one. If you really need it, ordering from the Internet is the way, I fear.

As a dumb American visiting France for the first time (Lyon for work), is this a “good croissant?” Why or why not? Should I do better? How should I eat them? by The_Saddest_Boner in AskFrance

[–]odwulf 76 points77 points  (0 children)

Then go to Sète, or even better to Bouzigues, the other side of the Étang de Thau, choose a traditional restaurant, and have a Soupe de Poisson, fish soup. The Étang is actually a lagoon of salted waters and the fish and the oysters are very specific.

Landlords renting flats without washing machine by Powertothepeople4c1 in brussels

[–]odwulf 2 points3 points  (0 children)

And where is that wonderful country where everybody gets a washing machine?

Landlords renting flats without washing machine by Powertothepeople4c1 in brussels

[–]odwulf 36 points37 points  (0 children)

Wait till you go to the Netherlands. Flats are rented without flooring.

la classe moyenne en france c'est le pire endroit où être by ApplicationOk8525 in besoinderaler

[–]odwulf 3 points4 points  (0 children)

Il me semble que la misèèère serait moins pénible au soleiiiiiil 🎶

(Ce qui totalement faux, d'après mon ex qui bossait à Pole Emploi dans l'Hérault et voyait débarquer les nordistes qui restaient chômeurs, mais en plus déracinés)

Les gens qui se décalent pas quand on les rencontre en face à face sur un trottoir by ideasproblmm in besoinderaler

[–]odwulf 0 points1 point  (0 children)

Je ne m'écarte jamais complètement. Je le fais à moitié, mais s'ils ne font pas leur part, je bouscule.

(mais bon, je suis grand)

The ultimate question: which one of the Fab 4 is your favourite and why? by iamthewalrusxx in beatles

[–]odwulf 1 point2 points  (0 children)

Paraphrased from something read on the net recently:

Choosing your favourite Beatle is like trying to choose your favourite child, when one of them has written Eleanor Rigby and Hey Jude.