Skip to content

Commit 34da948

Browse files
committed
merge
2 parents 7cc693b + a2a689e commit 34da948

File tree

2 files changed

+28
-21
lines changed

2 files changed

+28
-21
lines changed

README.md

+20-20
Original file line numberDiff line numberDiff line change
@@ -5,66 +5,66 @@ Escribo un apunte por mes mientras estudio.
55
Con estos apuntes no busco compartir un conocimiento profundo, sino, busco compartir una idea clara sobre un tema, para que cada uno pueda profundizar en los temas que le llaman la atención.
66
<!--lista_apuntes-->
77
## Lista de apuntes
8+
- [Algoritmos](apuntes/Algoritmos.md)
89
- [Acoplamiento entre componentes](apuntes/Acoplamiento%20entre%20componentes.md)
910
- [Análisis orientado a objetos (AOO)](apuntes/Analisis%20orientado%20a%20objetos%20(AOO).md)
1011
- [Arquitectura](apuntes/Arquitectura.md)
11-
- [Cohesión en componentes](apuntes/Cohesion%20en%20componentes.md)
12-
- [Algoritmos](apuntes/Algoritmos.md)
1312
- [Arreglos](apuntes/Arreglos.md)
14-
- [Cohesión y acoplamiento](apuntes/Cohesion%20y%20acoplamiento.md)
1513
- [Base de datos](apuntes/Base%20de%20datos.md)
14+
- [Cohesión en componentes](apuntes/Cohesion%20en%20componentes.md)
15+
- [Cohesión y acoplamiento](apuntes/Cohesion%20y%20acoplamiento.md)
1616
- [Complejidad ciclomática (CC)](apuntes/Complejidad%20ciclomatica%20(CC).md)
1717
- [Complejidad](apuntes/Complejidad.md)
18-
- [Desarrollo guiado por comportamiento (BDD)](apuntes/Desarrollo%20guiado%20por%20comportamiento%20(BDD).md)
1918
- [Desarrollo ágil](apuntes/Desarrollo%20agil.md)
19+
- [Desarrollo guiado por comportamiento (BDD)](apuntes/Desarrollo%20guiado%20por%20comportamiento%20(BDD).md)
2020
- [Desarrollo guiado por pruebas](apuntes/Desarrollo%20guiado%20por%20pruevas%20(TDD).md)
21-
- [Diagrama de contexto de sistema](apuntes/Diagrama%20de%20contexto%20de%20sistema.md)
2221
- [Diagrama de secuencia básico](apuntes/Diagrama%20de%20secuencia%20basico.md)
2322
- [Diseño por contrato](apuntes/Disenno%20por%20contrato.md)
2423
- [Documentación](apuntes/Documentacion.md)
2524
- [Diseño orientado a objetos (DOO)](apuntes/Disenno%20orientado%20a%20objetos%20(DOO).md)
25+
- [Documentos de diseño y documento de producto](apuntes/Documentos%20de%20disenno%20y%20documento%20de%20producto.md)
2626
- [Dominio y negocio](apuntes/Dominio%20y%20negocio.md)
2727
- [Estado y su gestión](apuntes/Estado%20y%20su%20gestion.md)
28-
- [Documentos de diseño y documento de producto](apuntes/Documentos%20de%20disenno%20y%20documento%20de%20producto.md)
2928
- [Estructuras de datos](apuntes/Estructuras%20de%20datos.md)
29+
- [Evita la herencia](apuntes/Evita%20la%20herencia.md)
3030
- [Funciones](apuntes/Funciones.md)
3131
- [GRASP](apuntes/GRASP.md)
3232
- [Historias de usuario](apuntes/Historias%20de%20usuario.md)
33-
- [Evita la herencia](apuntes/Evita%20la%20herencia.md)
3433
- [La ley de demeter](apuntes/La%20ley%20de%20demeter.md)
35-
- [Leyes en la evolución de aplicaciones](apuntes/Leyes_en_la_evolucion_de_aplicaciones.md)
36-
- [Más fácil de cambiar (ETC)](apuntes/Mas%20facil%20de%20cambiar%20(STR).md)
3734
- [Método de trabajo Kanban](apuntes/Metodo%20de%20trabajo%20Kanban.md)
3835
- [Método de priorización MoSCoW](apuntes/Metodo_de_priorizacion_MoSCoW.md)
3936
- [Modelo de arquitectura C4](apuntes/Modelo_de_arquitectura_C4.md)
4037
- [Modelo Kano](apuntes/Modelo_kano.md)
38+
- [No me hagas pensar ni me des sorpresas](apuntes/No%20me%20hagas%20pensar%20ni%20me%20des%20sorpresas.md)
4139
- [Niveles de abstracción](apuntes/Niveles%20de%20abstraccion.md)
4240
- [No te repitas (DRY)](apuntes/No%20te%20repitas%20(DRY).md)
43-
- [No me hagas pensar ni me des sorpresas](apuntes/No%20me%20hagas%20pensar%20ni%20me%20des%20sorpresas.md)
4441
- [No vas a necesitarlo (YANGI)](apuntes/No%20vas%20a%20necesitarlo%20(YANGI).md)
4542
- [Normalización](apuntes/Normalizacion.md)
46-
- [Notación Big O](apuntes/Notacion%20Big%20O.md)
4743
- [Ortogonalidad](apuntes/Ortogonalidad.md)
44+
- [Notación Big O](apuntes/Notacion%20Big%20O.md)
45+
- [Paradigmas de programación](apuntes/Paradigmas%20de%20programacion.md)
4846
- [Patrón MVC (Modelo, Vista y Controlador)](apuntes/Patron%20MVC%20(Modelo,%20vista%20y%20controlador).md)
4947
- [Patrón del objeto modesto](apuntes/Patron%20del%20objeto%20modesto.md)
50-
- [Paradigmas de programación](apuntes/Paradigmas%20de%20programacion.md)
5148
- [Patrón entidad-control-limite](apuntes/Patron%20entidad-control-limite.md)
52-
- [Patrones de diseño creacionales](apuntes/Patrones%20de%20diseño%20creacionales.md)
5349
- [Patrón repositorio](apuntes/Patron_repositorio.md)
54-
- [Principios SOLID](apuntes/Principios%20SOLID.md)
50+
- [Patrones de diseño creacionales](apuntes/Patrones%20de%20diseño%20creacionales.md)
51+
- [Principio KISS](apuntes/Principio%20KISS.md)
5552
- [Programa una interfaz antes que una implementación](apuntes/Programa%20una%20interfaz%20antes%20que%20una%20implementacion.md)
53+
- [Principios SOLID](apuntes/Principios%20SOLID.md)
5654
- [Programación básica](apuntes/Programacion%20basica.md)
57-
- [Pruebas unitarias](apuntes/Pruevas%20unitarias.md)
5855
- [Programación orientada a objetos (POO)](apuntes/Programacion%20orientada%20a%20objetos%20(POO).md)
59-
- [TDD y BDD diferencias](apuntes/TDD%20y%20BDD%20diferencias.md)
60-
- [Principio KISS](apuntes/Principio%20KISS.md)
56+
- [Pruebas unitarias](apuntes/Pruevas%20unitarias.md)
6157
- [Refactorización](apuntes/Refactorizacion.md)
62-
- [Tell don´t ask](apuntes/Tell%20dont%20ask.md)
6358
- [Sincronía y asincronía](apuntes/Sincronia%20y%20asincronia.md)
59+
- [TDD y BDD diferencias](apuntes/TDD%20y%20BDD%20diferencias.md)
60+
- [Tell don´t ask](apuntes/Tell%20dont%20ask.md)
6461
- [Teoría de conjuntos](apuntes/Teoria%20de%20conjuntos.md)
65-
- [Testing](apuntes/Testing.md)
6662
- [Tipos de relaciones entre clases](apuntes/Tipos%20de%20relaciones%20entre%20clases.md)
63+
- [Testing](apuntes/Testing.md)
6764
- [Tipos](apuntes/Tipos.md)
68-
- [Arquitectura por capas](apuntes/arquitectura%20por%20capas.md)
6965
- [Value object](apuntes/Value_object.md)
66+
- [Arquitectura por capas](apuntes/arquitectura%20por%20capas.md)
67+
- [Más fácil de cambiar (ETC)](apuntes/Mas%20facil%20de%20cambiar%20(STR).md)
68+
- [Diagrama de contexto de sistema](apuntes/Diagrama%20de%20contexto%20de%20sistema.md)
69+
- [Leyes en la evolución de aplicaciones](apuntes/Leyes_en_la_evolucion_de_aplicaciones.md)
7070
<!--lista_apuntes-->

generarListaDeApuntes.js

+8-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ const fs = require('fs');
44

55
const RELATIVE_PATH_OF_NOTES_FOLDER = 'apuntes/'
66

7+
// Gets the list of the notes inside the 'apuntes/' folder
78
fs.readdir(RELATIVE_PATH_OF_NOTES_FOLDER, (err, listOfNoteFiles) => {
89
if (err) {
910
console.error('Error al leer directorio ', err)
@@ -13,9 +14,12 @@ fs.readdir(RELATIVE_PATH_OF_NOTES_FOLDER, (err, listOfNoteFiles) => {
1314
console.table(listOfNoteFiles);
1415

1516
const notes = []
17+
18+
listOfNoteFiles.sort()
1619
listOfNoteFiles.forEach((nameOfNoteFile, index) => {
1720
const RELATIVE_PATH_OF_NOTE_FILE = `${RELATIVE_PATH_OF_NOTES_FOLDER}${nameOfNoteFile}`;
1821

22+
// Gets the content of each note
1923
fs.readFile(RELATIVE_PATH_OF_NOTE_FILE, 'utf-8', (err, noteContent) => {
2024
if (err) {
2125
console.error('Error al leer apunte (note) ', err);
@@ -32,6 +36,7 @@ fs.readdir(RELATIVE_PATH_OF_NOTES_FOLDER, (err, listOfNoteFiles) => {
3236

3337
let noteYear = noteContentPerLine[1].split('_').at(-1)
3438

39+
// We only use the title and RELATIVE_PATH attributes, but we may use the rest in the future
3540
const note = {
3641
title: noteTitle,
3742
formattedDate,
@@ -44,13 +49,15 @@ fs.readdir(RELATIVE_PATH_OF_NOTES_FOLDER, (err, listOfNoteFiles) => {
4449

4550
notes.push(`- [${note.title}](${note.RELATIVE_PATH.split(' ').join('%20')})`)
4651

52+
// Checks if all the notes are in notes array
4753
const isThisTheLastNote = (listOfNoteFiles.length - 1) === index;
4854
if (isThisTheLastNote) {
49-
// Now the whole notes are in notes array
55+
// Modify the README.md file to include the list of notes
5056
fs.readFile('README.md', 'utf-8', (err, readmeContent) => {
5157
if (err) {
5258
return console.error('Error al leer apunte (note) ', err);
5359
}
60+
5461
const readmeContentWithoutNoteList = readmeContent.split('<!--lista_apuntes-->')[0]
5562
const content = `${readmeContentWithoutNoteList}<!--lista_apuntes-->\n## Lista de apuntes\n${notes.join('\n')}\n<!--lista_apuntes-->`
5663
fs.writeFile('README.md', content, (err) => {

0 commit comments

Comments
 (0)