Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

name every function #77

Open
naturallymitchell opened this issue Nov 21, 2018 · 2 comments
Open

name every function #77

naturallymitchell opened this issue Nov 21, 2018 · 2 comments

Comments

@naturallymitchell
Copy link
Member

naturallymitchell commented Nov 21, 2018

similar to https://github.com/foundpatterns/torchbear/blob/master/install.sh

actions loader = load_actions()

count events
https://github.com/foundpatterns/lighttouch-base/blob/master/loaders/events.lua#L32-L36

tangentially related: #76

@Hellfar
Copy link
Collaborator

Hellfar commented Dec 6, 2018

I have made a PR for this: #95

@naturallymitchell
Copy link
Member Author

mitchell
good names
good structure
the loader has steps that accomplish loading
I don't like naming multiple functions load

Arnaud Castellanos
then we need definitions

mitchell
scan, parse, enumerate, .....

Arnaud Castellanos
write them somewhere if you'll make them
in a style guide

mitchell
let's do it now
what do you think the steps are?

Arnaud CastellanosLast Sunday at 7:36 PM
steps for?

mitchellLast Sunday at 7:36 PM
setting up lighttouch

Arnaud CastellanosLast Sunday at 7:37 PM
I think you want to refactor everything...

mitchellLast Sunday at 7:37 PM
each component has to go through some steps
just theme loader

Arnaud CastellanosLast Sunday at 7:37 PM
the code is outlining those steps, that's what it's for

mitchellLast Sunday at 7:38 PM
renaming a headline or two in an outline can help it significantly

Arnaud CastellanosLast Sunday at 7:40 PM
loading a theme is:

  • going through each file in it's subdirectories
  • reading the file and add it to a file list
  • determine the parents and repeat the steps with those
    then lighttouch:
  • loads the main theme (implicitly with its parents)
  • combine all of their files into a single file list
  • setup tera with that file list(edited)

mitchellLast Sunday at 7:41 PM
can you make names for those?, in a systematic sense

Arnaud CastellanosLast Sunday at 7:42 PM
the first two steps are combined, together they are "scan_subdir"
"load theme" asks scan_subdir to do the first two and then does the third
load_themes asks load_theme to do that for each them and then does the last three
the first three cannot be in the same level of the last because they are per theme

mitchellLast Sunday at 7:44 PM
"scan_subdir" accomplishes what exactly?

Arnaud CastellanosLast Sunday at 7:44 PM

  • going through each file in it's subdirectories
  • reading the file and add it to a file list

mitchellLast Sunday at 7:44 PM
I mean in an nominological sense

Arnaud CastellanosLast Sunday at 7:44 PM
what's that?

mitchellLast Sunday at 7:44 PM
(named)

Arnaud CastellanosLast Sunday at 7:44 PM
I don't understand

mitchellLast Sunday at 7:45 PM
like, "ir a la playa" is a named activity

Arnaud CastellanosLast Sunday at 7:45 PM
uh, scans the subdirectories?
reads all the files in a subdirectory (recursively) and add them to a list(edited)

mitchellLast Sunday at 7:46 PM
enumerate, right?

Arnaud CastellanosLast Sunday at 7:47 PM
if enumerate is asigning a number to stuff... no

mitchellLast Sunday at 7:47 PM
make a list
"list_themes"?

Arnaud CastellanosLast Sunday at 7:48 PM
it doesn't make the list, and not to themes, adds the files of a theme to a list

mitchellLast Sunday at 7:49 PM
"list_themes_templates"?(edited)

Arnaud CastellanosLast Sunday at 7:49 PM
what's list? making a list?

mitchellLast Sunday at 7:49 PM
yes

Arnaud CastellanosLast Sunday at 7:49 PM
doesn't make it(edited)
adds them to one
I don't know if that counts in the defintion

mitchellLast Sunday at 7:50 PM
It's making a table, I guess.. not a list

Arnaud CastellanosLast Sunday at 7:50 PM
the table is the lua term, I think
isn't a table what one uses to eat?

mitchellLast Sunday at 7:50 PM
true

Arnaud CastellanosLast Sunday at 7:51 PM
no, table is like a grid, right?

mitchellLast Sunday at 7:51 PM
that too

Arnaud CastellanosLast Sunday at 7:51 PM
that's the term
it's confusing tbh
the second one is also tabla in spanish, but tabla is a plank

mitchell
would it be possible for us to use sets??????

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants