C File Gen, un générateur de fichiers
C File Gen (CFG pour son diminutif), est un générateur de fichiers (style de template) pour le Langage C. Les fichiers générés sont ceux utilisés pour le code (*.c et *.h) mais avec toute l'organisation et l'en-tête de projet/fichier déjà en place.
Cela fait gagner un temps considérable lorsqu'il faut créer des dizaines de fichiers avec la même organisation, plus besoin de procéder à de multitudes Copier/Coller !
Voici ce qu'on obtenir avec CFG (avec les fichiers de gabarit par défaut) :
Un fichier source :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57
| /*
* This file is part of CFG.
* Copyright (C) 2008 by HECHT Franck
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/* --------------------------------------------------------------------------
CFG
--------------------------------------------------------------------------
File : test
Author : HECHT Franck - (C) 2008
Mail : franhec@gmail.com
Creation : 05/08/2008 14:20:41
Desc : Short desctiption of this module.
--------------------------------------------------------------------------
Last modifications:
-------------------------------------------------------------------------- */
#ifdef __cplusplus
#error This source file is not C++ but rather C. Please use a C-compiler
#endif
#include "test.h"
/* macros =================================================================== */
/* constants ================================================================ */
/* types ==================================================================== */
/* structures =============================================================== */
/* private variables ======================================================== */
/* private functions ======================================================== */
/* internal public functions ================================================ */
/* entry points ============================================================= */
/* public variables ========================================================= */
/* --------------------------------------------------------------------------
File generated with: C File Gen (Alpha) v0.1.0 - by HECHT Franck (C) 2008
-------------------------------------------------------------------------- */ |
Le fichier d'en-tête associé :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64
| /*
* This file is part of CFG.
* Copyright (C) 2008 by HECHT Franck
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/* --------------------------------------------------------------------------
CFG
--------------------------------------------------------------------------
File : test
Author : HECHT Franck - (C) 2008
Mail : franhec@gmail.com
Creation : 05/08/2008 14:20:41
Desc : Short desctiption of this module.
--------------------------------------------------------------------------
Last modifications:
-------------------------------------------------------------------------- */
#ifndef H_HF_TEST_5820081420
#define H_HF_TEST_5820081420
#ifdef __cplusplus
extern "C" {
#endif
/* macros =================================================================== */
/* constants ================================================================ */
/* types ==================================================================== */
/* structures =============================================================== */
/* internal public functions ================================================ */
/* entry points ============================================================= */
/* public variables ========================================================= */
#ifdef __cplusplus
}
#endif
#endif
/* --------------------------------------------------------------------------
File generated with: C File Gen (Alpha) v0.1.0 - by HECHT Franck (C) 2008
-------------------------------------------------------------------------- */ |
Le type de présentation peut être changé simplement en modifiant le contenu des fichiers de gabarit et il est également possible d'omettre certaines parties.
Ressources pour C File Gen
Voici les différentes ressources pour C File Gen :
Site : http://franckh.developpez.com/cfg/index.html
Le blog : http://blog.developpez.com/franckh
Documentation en ligne : http://franckh.developpez.com/cfg/doc
Documentation PDF : http://franckh.developpez.com/cfg/do...tion-fr-v1.pdf
Dépot SubVersion :
Code:
svn export http://subversion.developpez.com/projets/CFG/ cfg
Téléchargement des sources : ftp://ftp-developpez.com/franckh/cfg...v0.1.1-src.zip
Téléchargement de la version compilée (pour Windows) : ftp://ftp-developpez.com/franckh/cfg...-bin-win32.zip