diff options
Diffstat (limited to 'archivo.py')
-rw-r--r-- | archivo.py | 12 |
1 files changed, 7 insertions, 5 deletions
@@ -34,12 +34,14 @@ def abrir_efemeride(): texto = pickle.load(archivo) return texto -def guardar_dato(indice, contenido, archivo): +def guardar_dato(indice, contenido): '''get a id dependig of the unix time, and the content''' indice = str(indice) - dict = {} - dict[indice] = contenido - f = open(archivo, 'w') - pickle.dump(dict, f) + dia = {} + activ = [] + activ.append(contenido) + dia[indice] = activ + f = open('files/actividades.pkl', 'w') + pickle.dump(dia, f) f.close() |