This channel is intended for people just starting with the Raku Programming Language (raku.org). Logs are available at irclogs.raku.org/raku-beginner/live.html
Set by lizmat on 8 June 2022.
01:24 Tirifto left 01:26 Tirifto joined 02:19 Manifest0 left 06:50 CIAvash joined 07:31 CIAvash left 07:37 CIAvash joined 07:38 CIAvash left 07:39 CIAvash joined 07:49 CIAvash left 07:52 CIAvash joined 08:08 CIAvash left 11:20 Manifest0 joined
dano How is a multi-file Raku project organized? Let's say I have a main file which does something and a Util file with some utilities that is used by the main file. How do I use the utility file in the main file? 11:51
11:57 Manifest0 left
lizmat one usually creates a distribution for the project (e.g. with App::Mi6) 12:01
list utility modules as being provided by that distribution
and then -use- the utility module in the main file 12:02
gfldex dano: this might help, if you don't want to fiddle with project management: gist.github.com/gfldex/afe6a3cd8f7...4f8d4a30e7 13:20
librasteve both lizmat and gfldex are right as the "proper" way to do this ... but if you are just chucking some code together and do not need directory independence you can do something as simple as add the line 13:25
lizmat please, please, please, don't tell newbies to use "use lib" :-( 13:26
librasteve use lib '.'; use util;
lizmat well, use lib with a specific dir ? 13:33
dano I guess I will have to look into creating distributions 13:36
gfldex `use lib '.'` is very relative and if you ever spot it in production, you are well adviced to leave that company.
lizmat dano: modules like App::Mi6 are a great help with that: $ mi6 new Project::Name 13:37
and you're set
librasteve well, I often use raku to chuck together code and (provided you know the limitations) not sure that its so bad (but I agree that it is only for quick and dirty stuff on my local machine)
lizmat ++
gfldex @librasteve You are free to do so. Just don't be sad because some lee7 haxor replaces you `Util.rakumod` with theirs. 13:38
librasteve docs.raku.org/language/modules#Cre...ng_modules is a thorough intro 13:39
guess I'll have to fire myself now 13:40
gfldex That may be more convenient then having your door kick in by the cops. :) 13:41
dano What kind of development environments are you guys using? 14:05
Do you use a debugger? How? 14:06
gfldex raku.land/?q=debugger
lizmat is oldskool and used vi
*uses
gfldex commaide.com/
I personally use vim, but I don't do big projects with Raku. 14:07
15:01 Manifest0 joined
antononcube I use two IDEs: Comma and Jupyter. 15:17
I gave Emacs a try too, since, it is faster start. But since I moved to more intensively using LLMs I need a more serious interactive solution, hence I have Visual Studio Code with Jupyter always open. 15:20
Commaide is very good, but crashes often and it has some very ā€œinterestingā€ idiosyncrasies. I was buying its provisional version for years, until earlier last year ā€” for close to year they did not release version that did not crash when I open a more complicated grammar file. 15:24
librasteve i use Comma IDE ... and vi 16:10
comma ide never crashed on me --- my biggest grammar is 100 lines ish 16:12
antononcube "Reliably" crashed for close to year. There was also no way to communicate that -- they say in their site to report bugs through Commaide. Well, how to report crashes then?! šŸ™‚ youtu.be/ArnkFpJOKDE 16:29
I did that video and posted a link to it on their message board. (I misread the bug-repor instructions.) 16:31
I would say, Raku-wise, Commaide is indispensable for me at this point. But basically every update needs to pass a certain "quarantine" period and "prove itself" it does not crash too often. 16:35
18:13 teatwo left
lucs lizmat: What do you think of use lib $?FILE.IO.dirname ? 19:08
That's what I use for quick and dirty (famous last words) projects. 19:31
dano Comma IDE sounds good for large projects, but for now I am getting along with Emacs with raku-mode providing just basic syntax highlighting 20:04
I checked and there appears to some kindof LSP for VS Code, but no standalone LSP that I could plug into an editor like emacs. I wonder why? Is making an LSP a lot of effort? 20:06
antononcube Well, simply put it is not a trivial tasks, and each editor / IDE has its own ideas about it. 20:07
dano I thought the point of LSPs is that it is editor-independent 20:08
The editor-dependent part would be the client 20:09
antononcube Well, I do not think their transfer that easily or directly.
BTW, I was strongly considering making a "raku mode" for Geany. It seemed easy, but there is a fair amount of learning and testing that have to be done in order to have that "raku mode" work really well. 20:10
dano Very cool
That's the trouble with software, it is so much work to make it good enough to publish 20:11
antononcube Sure! But, that is why programmers get employed... 20:12
dano Do you like your job?
antononcube As a rule, I do not divulge personal information in public forums. 20:14
Meaning, you are too new here, you might be a plant from the HR of my company.
dano Haha
Ok, no problem 20:15
antononcube @dano Do you use org-mode in Emacs? 20:18
dano I just started learning emacs some months ago, using it to learn new languages. I tried orgmode a bit but I don't use it regularly 20:21
Very simple stuff, headers, lists and such 20:22
antononcube I am trying to promote the use of Literate Programming (LT) in Raku. LT in org-mode is/was one of the ways to get rakuns adopting LT.
dano I never figured out how to quickly switch between a rendered and markup view without having to publish the orgmode doc 20:23
What is that?
antononcube Hmm... I am not sure I have used "rendered view" of org-mode in Emacs. I think I just use "org-indent-mode". 20:24
scullucs Why is it called LT (I'd have expected LP, eh)? 20:26
antononcube en.wikipedia.org/wiki/Literate_programming 20:27
dano Yeah, in the end I figured that a "rendered view" didn't even exist, i.e. I would always be looking at the markdown and rarely at the final product
antononcube @lucs Yes, "LT" is wrong. 20:28
scullucs Yeah, Literate Programming is a great idea, I've been hearing about it for years. 20:29
You've got some stuff for doing it in Raku?
antononcube @lucs Yes, three ways, using: - Raku package "Text::CodeProcessing" - Raku packages "Jupyter::Kernel" or "Jupyter::Chatbook" - Mathematica paclet "RakuMode" 20:31
scullucs Aha, thanks. 20:34
dano I had never heard of LP before. It seems like it would take a lot a getting used to
antononcube I have made a 6-10 videos about those. Here are a few: - "Raku Literate Programming via command line pipelines", (4.5 min), www.youtube.com/watch?v=2UjAdQaKof8 - "Conversion and evaluation of Raku files", (18 min), www.youtube.com/watch?v=GJO7YqjGn6o - "Jupyter Chatbook multi cell LLM chats teaser (Raku)", (4.25 min), www.youtube.com/watch?v=wNpIGUAwZB8 20:37
scullucs Noted, thanks. 20:46
aruniecrisps Is Cro generally the most popular set of web libraries for Raku? Just curious 23:50