diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ca39541..6e3706d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,3 +1,19 @@ +# A safe, Rust-native binding for the SWORD library +# Copyright (C) 2025 Gregory Hellings +# +# 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; version 2. +# +# 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, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + stages: - check - build diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..c6711e1 --- /dev/null +++ b/LICENSE @@ -0,0 +1,13 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to diff --git a/build.rs b/build.rs index bec23dc..41d42c7 100644 --- a/build.rs +++ b/build.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ use system_deps; fn main() { diff --git a/flake.nix b/flake.nix index d80c7be..7ead4d4 100644 --- a/flake.nix +++ b/flake.nix @@ -1,4 +1,18 @@ -# github.com/brianmcgee has lots of great ideas for going above and beyond for this +# A safe, Rust-native binding for the SWORD library +# Copyright (C) 2025 Gregory Hellings +# +# 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; version 2. +# +# 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, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. { description = "Greg's homepage"; inputs = { diff --git a/src/cxx/mgr.cc b/src/cxx/mgr.cc index 9181ffc..8c194b3 100644 --- a/src/cxx/mgr.cc +++ b/src/cxx/mgr.cc @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #include "mgr.h" #include diff --git a/src/cxx/mgr.h b/src/cxx/mgr.h index 68361eb..0ab56e7 100644 --- a/src/cxx/mgr.h +++ b/src/cxx/mgr.h @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #pragma once #include diff --git a/src/cxx/mod.rs b/src/cxx/mod.rs index 95c622b..3a2c16d 100644 --- a/src/cxx/mod.rs +++ b/src/cxx/mod.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #[cxx::bridge(namespace = "sword_rs")] pub mod ffi { unsafe extern "C++" { diff --git a/src/cxx/module.cc b/src/cxx/module.cc index 1cf14e9..eac1d5a 100644 --- a/src/cxx/module.cc +++ b/src/cxx/module.cc @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #include "module.h" namespace sword_rs { diff --git a/src/cxx/module.h b/src/cxx/module.h index e0eda35..815f41b 100644 --- a/src/cxx/module.h +++ b/src/cxx/module.h @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #pragma once #include diff --git a/src/cxx/versekey.cc b/src/cxx/versekey.cc index b2a25b1..1e75631 100644 --- a/src/cxx/versekey.cc +++ b/src/cxx/versekey.cc @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #include "versekey.h" #include diff --git a/src/cxx/versekey.h b/src/cxx/versekey.h index 04491ca..0ee45f4 100644 --- a/src/cxx/versekey.h +++ b/src/cxx/versekey.h @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #pragma once #include diff --git a/src/cxx/versification.cc b/src/cxx/versification.cc index 35202e1..92cc36c 100644 --- a/src/cxx/versification.cc +++ b/src/cxx/versification.cc @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #include "versification.h" #include "rust/cxx.h" diff --git a/src/cxx/versification.h b/src/cxx/versification.h index bc11b16..6625021 100644 --- a/src/cxx/versification.h +++ b/src/cxx/versification.h @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ #pragma once #include diff --git a/src/lib.rs b/src/lib.rs index 587ce8f..cfcce48 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ mod cxx; pub mod mgr; pub mod module; diff --git a/src/main.rs b/src/main.rs index 9ec79b2..3740e1b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ use rand::Rng; use sword_rs::mgr::{Format, Mgr}; diff --git a/src/mgr.rs b/src/mgr.rs index 656ccd9..2c277c5 100644 --- a/src/mgr.rs +++ b/src/mgr.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ use crate::cxx::ffi; use crate::module::Module; use cxx::UniquePtr; diff --git a/src/module.rs b/src/module.rs index 3da9397..21f8f67 100644 --- a/src/module.rs +++ b/src/module.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ use crate::cxx::ffi; use cxx::UniquePtr; diff --git a/src/versekey.rs b/src/versekey.rs index 1b3be99..245b315 100644 --- a/src/versekey.rs +++ b/src/versekey.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ use crate::cxx::ffi; use std::fmt; diff --git a/src/versification.rs b/src/versification.rs index cc83b32..7b63f85 100644 --- a/src/versification.rs +++ b/src/versification.rs @@ -1,3 +1,21 @@ +/* + * A safe, Rust-native binding for the SWORD library + * Copyright (C) 2025 Gregory Hellings + * + * 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; version 2. + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + */ /// Rust-friendly wrapper for the CXX versification bridge. use crate::cxx::ffi; use cxx::UniquePtr;