mirror of
https://github.com/depp/syncfiles.git
synced 2024-06-15 17:29:49 +00:00
Make source file headers consistent
- Standardize copyright and license notice - Standardize header guards
This commit is contained in:
parent
ad220442d7
commit
3bf095fb49
7
.header
Normal file
7
.header
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
width = 80
|
||||||
|
tabsize = 4
|
||||||
|
guards = true
|
||||||
|
copyright_notice = <<EOF
|
||||||
|
This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
EOF
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "convert/convert.h"
|
#include "convert/convert.h"
|
||||||
|
|
||||||
struct ConvertEngine {
|
struct ConvertEngine {
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef convert_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define convert_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef CONVERT_CONVERT_H
|
||||||
|
#define CONVERT_CONVERT_H
|
||||||
/* convert.h - character set conversion routines. */
|
/* convert.h - character set conversion routines. */
|
||||||
|
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
/* convert_1f.c - Forward conversion from extended ASCII to UTF-8. */
|
/* convert_1f.c - Forward conversion from extended ASCII to UTF-8. */
|
||||||
#include "convert/convert.h"
|
#include "convert/convert.h"
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
/* convert_1r.c - Reverse conversion from UTF-8 to extended ASCII. */
|
/* convert_1r.c - Reverse conversion from UTF-8 to extended ASCII. */
|
||||||
#include "convert/convert.h"
|
#include "convert/convert.h"
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "convert/convert.h"
|
#include "convert/convert.h"
|
||||||
#include "convert/data.h"
|
#include "convert/data.h"
|
||||||
#include "lib/test.h"
|
#include "lib/test.h"
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef data_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define data_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef CONVERT_DATA_H
|
||||||
|
#define CONVERT_DATA_H
|
||||||
/* data.h - charmap data, not used for classic Mac OS builds */
|
/* data.h - charmap data, not used for classic Mac OS builds */
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,11 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef CONVERT_RESOURCES_H
|
||||||
|
#define CONVERT_RESOURCES_H
|
||||||
|
|
||||||
#define rSTRS_Charmaps 128
|
#define rSTRS_Charmaps 128
|
||||||
#define rSTRS_Scripts 129
|
#define rSTRS_Scripts 129
|
||||||
#define rSTRS_Regions 130
|
#define rSTRS_Regions 130
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "lib/crc32.h"
|
#include "lib/crc32.h"
|
||||||
|
|
||||||
static int gCRCInitted;
|
static int gCRCInitted;
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef CRC32_H
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define CRC32_H
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef LIB_CRC32_H
|
||||||
|
#define LIB_CRC32_H
|
||||||
|
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "lib/crc32.h"
|
#include "lib/crc32.h"
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef lib_defs_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define lib_defs_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef LIB_DEFS_H
|
||||||
|
#define LIB_DEFS_H
|
||||||
/* defs.h - common definitions. */
|
/* defs.h - common definitions. */
|
||||||
|
|
||||||
/*==============================================================================
|
/*==============================================================================
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef lib_endian_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define lib_endian_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef LIB_ENDIAN_H
|
||||||
|
#define LIB_ENDIAN_H
|
||||||
/* endian.h - byte order and byte swapping */
|
/* endian.h - byte order and byte swapping */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -72,4 +75,4 @@
|
||||||
|
|
||||||
#endif /* TARGET_API_MAC_OS8 */
|
#endif /* TARGET_API_MAC_OS8 */
|
||||||
|
|
||||||
#endif /* lib_endian_h */
|
#endif
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "lib/endian.h"
|
#include "lib/endian.h"
|
||||||
|
|
||||||
#include "lib/test.h"
|
#include "lib/test.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
/* Defined to get vsnprintf. */
|
/* Defined to get vsnprintf. */
|
||||||
#define _XOPEN_SOURCE 500
|
#define _XOPEN_SOURCE 500
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef test_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define test_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef LIB_TEST_H
|
||||||
|
#define LIB_TEST_H
|
||||||
/* test.h - unit testing definitions. */
|
/* test.h - unit testing definitions. */
|
||||||
|
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
/* toolbox.c - replacement functions for Mac OS toolbox functions
|
/* toolbox.c - replacement functions for Mac OS toolbox functions
|
||||||
|
|
||||||
This is used to run conversion tests on non-Mac OS systems to make
|
This is used to run conversion tests on non-Mac OS systems to make
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "lib/util.h"
|
#include "lib/util.h"
|
||||||
|
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef lib_util_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define lib_util_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef LIB_UTIL_H
|
||||||
|
#define LIB_UTIL_H
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
||||||
/* Print an error message and exit. */
|
/* Print an error message and exit. */
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "choose_directory.h"
|
#include "choose_directory.h"
|
||||||
|
|
||||||
#include "error.h"
|
#include "error.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_CHOOSE_DIRECTORY_H
|
#ifndef MACOS_CHOOSE_DIRECTORY_H
|
||||||
#define MACOS_CHOOSE_DIRECTORY_H
|
#define MACOS_CHOOSE_DIRECTORY_H
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "error.h"
|
#include "error.h"
|
||||||
|
|
||||||
#include "main.h"
|
#include "main.h"
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
// error.h - Error handling.
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_ERROR_H
|
#ifndef MACOS_ERROR_H
|
||||||
#define MACOS_ERROR_H
|
#define MACOS_ERROR_H
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "main.h"
|
#include "main.h"
|
||||||
|
|
||||||
#include "error.h"
|
#include "error.h"
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
// main.h - Main entry point.
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_MAIN_H
|
#ifndef MACOS_MAIN_H
|
||||||
#define MACOS_MAIN_H
|
#define MACOS_MAIN_H
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "path.h"
|
#include "path.h"
|
||||||
|
|
||||||
#include "error.h"
|
#include "error.h"
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
// path.h - Path manipulation utilities.
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_PATH_H
|
#ifndef MACOS_PATH_H
|
||||||
#define MACOS_PATH_H
|
#define MACOS_PATH_H
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "project.h"
|
#include "project.h"
|
||||||
|
|
||||||
#include "choose_directory.h"
|
#include "choose_directory.h"
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
// project.h - Synchronization projects.
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_PROJECT_H
|
#ifndef MACOS_PROJECT_H
|
||||||
#define MACOS_PROJECT_H
|
#define MACOS_PROJECT_H
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_RESOURCES_H
|
#ifndef MACOS_RESOURCES_H
|
||||||
#define MACOS_RESOURCES_H
|
#define MACOS_RESOURCES_H
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "strutil.h"
|
#include "strutil.h"
|
||||||
|
|
||||||
#include "error.h"
|
#include "error.h"
|
||||||
|
|
|
@ -1,4 +1,6 @@
|
||||||
// strutil.h - String utilities.
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_STRUTIL_H
|
#ifndef MACOS_STRUTIL_H
|
||||||
#define MACOS_STRUTIL_H
|
#define MACOS_STRUTIL_H
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "tempfile.h"
|
#include "tempfile.h"
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#ifndef MACOS_TEMPFILE_H
|
#ifndef MACOS_TEMPFILE_H
|
||||||
#define MACOS_TEMPFILE_H
|
#define MACOS_TEMPFILE_H
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef sync_meta_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define sync_meta_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef SYNC_META_H
|
||||||
|
#define SYNC_META_H
|
||||||
/* meta.h - file metadata */
|
/* meta.h - file metadata */
|
||||||
|
|
||||||
#include "lib/defs.h"
|
#include "lib/defs.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
#include "sync/tree.h"
|
#include "sync/tree.h"
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
|
@ -1,5 +1,8 @@
|
||||||
#ifndef sync_tree_h
|
// Copyright 2022 Dietrich Epp.
|
||||||
#define sync_tree_h
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
#ifndef SYNC_TREE_H
|
||||||
|
#define SYNC_TREE_H
|
||||||
/* tree.h - binary search trees of file metadata */
|
/* tree.h - binary search trees of file metadata */
|
||||||
|
|
||||||
#include "sync/meta.h"
|
#include "sync/meta.h"
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
// Copyright 2022 Dietrich Epp.
|
||||||
|
// This file is part of SyncFiles. SyncFiles is licensed under the terms of the
|
||||||
|
// Mozilla Public License, version 2.0. See LICENSE.txt for details.
|
||||||
|
|
||||||
#include "sync/tree.h"
|
#include "sync/tree.h"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user