diff --git a/.licensure.yml b/.licensure.yml index d6f385352..5216e839e 100644 --- a/.licensure.yml +++ b/.licensure.yml @@ -1,14 +1,57 @@ -author: ZomboDB, LLC -ident: MIT -email: zombodb@gmail.com +change_in_place: true excludes: - Cargo.toml - - ".*\\.h" - - "\\.cargo/config" + - Cargo.lock + - LICENSE + - pgx-utils/assets/ansi.tmTheme + - ".envrc" + - ".gitignore" + - "flake\\..*" + - "logo.*" + - ".github/**/*" + - ".cargo/config" - "cargo-pgx/src/templates/*" - - ".github/workflows/*" - ".*\\.control" - ".*\\.md" + - ".*\\.nix" - ".*\\.yml" - - ".*\\.sh" - - load-order.txt +licenses: + - files: any + ident: MIT + authors: + - name: Technology Concepts & Design, Inc. + email: support@tcdi.com + template: | + Portions Copyright 2019-2021 ZomboDB, LLC. + + Portions Copyright 2021-[year] [name of author] + + + All rights reserved. + + + Use of this source code is governed by the [ident] license that can be found in the LICENSE file. +comments: + - columns: 120 + extensions: + - rs + - c + - h + - sql + commenter: + type: block + start_block_char: "/*\n" + end_block_char: "\n*/\n" + - columns: 120 + extension: html + commenter: + type: block + start_block_char: "" + - columns: 80 + extension: any + commenter: + type: line + comment_char: "#" + trailing_lines: 0 + \ No newline at end of file diff --git a/LICENSE b/LICENSE index d12621791..b194cb3c4 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,8 @@ MIT License -Copyright (c) 2020 ZomboDB, LLC +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. . +All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 96602088a..a737ee52c 100644 --- a/README.md +++ b/README.md @@ -273,6 +273,8 @@ time goes on. Your feedback about what you'd like to be able to do with `pgx` i ## License ``` -Copyright 2020 ZomboDB, LLC . All rights reserved. +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. . +All rights reserved. Use of this source code is governed by the MIT license that can be found in the LICENSE file. ``` diff --git a/cargo-pgx/src/command/connect.rs b/cargo-pgx/src/command/connect.rs index bca6ed1a7..e989823fd 100644 --- a/cargo-pgx/src/command/connect.rs +++ b/cargo-pgx/src/command/connect.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ command::{get::get_property, run::exec_psql, start::start_postgres}, @@ -47,11 +53,13 @@ impl CommandExecute for Connect { // It's actually the dbname! We should infer from the manifest. self.dbname = Some(pg_version); - let metadata = crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) - .wrap_err("couldn't get cargo metadata")?; + let metadata = + crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) + .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; let package_manifest = Manifest::from_path(&package_manifest_path) .wrap_err("Couldn't parse manifest")?; @@ -62,11 +70,13 @@ impl CommandExecute for Connect { }, None => { // We should infer from the manifest. - let metadata = crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) - .wrap_err("couldn't get cargo metadata")?; + let metadata = + crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) + .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; let package_manifest = Manifest::from_path(&package_manifest_path) .wrap_err("Couldn't parse manifest")?; @@ -80,16 +90,18 @@ impl CommandExecute for Connect { Some(dbname) => dbname, None => { // We should infer from package - let metadata = crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) - .wrap_err("couldn't get cargo metadata")?; + let metadata = + crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) + .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; get_property(&package_manifest_path, "extname") .wrap_err("could not determine extension name")? .ok_or(eyre!("extname not found in control file"))? - }, + } }; connect_psql(Pgx::from_config()?.get(&pg_version)?, &dbname) diff --git a/cargo-pgx/src/command/get.rs b/cargo-pgx/src/command/get.rs index a20731f6d..24dd2cf55 100644 --- a/cargo-pgx/src/command/get.rs +++ b/cargo-pgx/src/command/get.rs @@ -1,6 +1,13 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ + +use crate::CommandExecute; use eyre::{eyre, WrapErr}; use std::{ fs::File, @@ -8,7 +15,6 @@ use std::{ path::{Path, PathBuf}, process::Command, }; -use crate::CommandExecute; /// Get a property from the extension control file #[derive(clap::Args, Debug)] @@ -32,8 +38,9 @@ impl CommandExecute for Get { let metadata = crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; if let Some(value) = get_property(&package_manifest_path, &self.name)? { println!("{}", value); @@ -79,22 +86,37 @@ pub fn get_property(manifest_path: impl AsRef, name: &str) -> eyre::Result Ok(None) } -pub(crate) fn find_control_file(manifest_path: impl AsRef) -> eyre::Result<(PathBuf, String)> { - let parent = manifest_path - .as_ref() - .parent() - .ok_or_else(|| eyre!("could not get parent of `{}`", manifest_path.as_ref().display()))?; - - for f in std::fs::read_dir(parent) - .wrap_err_with(|| eyre!("cannot open current directory `{}` for reading", parent.display()))? { +pub(crate) fn find_control_file( + manifest_path: impl AsRef, +) -> eyre::Result<(PathBuf, String)> { + let parent = manifest_path.as_ref().parent().ok_or_else(|| { + eyre!( + "could not get parent of `{}`", + manifest_path.as_ref().display() + ) + })?; + + for f in std::fs::read_dir(parent).wrap_err_with(|| { + eyre!( + "cannot open current directory `{}` for reading", + parent.display() + ) + })? { if f.is_ok() { if let Ok(f) = f { let f_path = f.path(); if f_path.extension() == Some("control".as_ref()) { - let file_stem = f_path.file_stem() - .ok_or_else(|| eyre!("could not get file stem of `{}`", f_path.display()))?; - let file_stem = file_stem.to_str() - .ok_or_else(|| eyre!("could not get file stem as String from `{}`", f_path.display()))? + let file_stem = f_path.file_stem().ok_or_else(|| { + eyre!("could not get file stem of `{}`", f_path.display()) + })?; + let file_stem = file_stem + .to_str() + .ok_or_else(|| { + eyre!( + "could not get file stem as String from `{}`", + f_path.display() + ) + })? .to_string(); return Ok((f_path, file_stem)); } @@ -102,7 +124,10 @@ pub(crate) fn find_control_file(manifest_path: impl AsRef) -> eyre::Result } } - Err(eyre!("control file not found in `{}`", manifest_path.as_ref().display())) + Err(eyre!( + "control file not found in `{}`", + manifest_path.as_ref().display() + )) } fn determine_git_hash() -> eyre::Result> { diff --git a/cargo-pgx/src/command/init.rs b/cargo-pgx/src/command/init.rs index 8855a84b0..8c6e28435 100644 --- a/cargo-pgx/src/command/init.rs +++ b/cargo-pgx/src/command/init.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::command::stop::stop_postgres; use crate::CommandExecute; @@ -435,7 +441,8 @@ pub(crate) fn initdb(bindir: &PathBuf, datadir: &PathBuf) -> eyre::Result<()> { let command_str = format!("{:?}", command); tracing::debug!(command = %command_str, "Running"); - let output = command.output() + let output = command + .output() .wrap_err_with(|| eyre!("unable to execute: {}", command_str))?; tracing::trace!(command = %command_str, status_code = %output.status, "Finished"); diff --git a/cargo-pgx/src/command/install.rs b/cargo-pgx/src/command/install.rs index d161a8093..dd1a5a382 100644 --- a/cargo-pgx/src/command/install.rs +++ b/cargo-pgx/src/command/install.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ command::get::{find_control_file, get_property}, @@ -47,10 +53,11 @@ impl CommandExecute for Install { let metadata = crate::metadata::metadata(&self.features, self.manifest_path.as_ref()) .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; - let package_manifest = Manifest::from_path(&package_manifest_path) - .wrap_err("Couldn't parse manifest")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; + let package_manifest = + Manifest::from_path(&package_manifest_path).wrap_err("Couldn't parse manifest")?; let pg_config = match self.pg_config { None => PgConfig::from_path(), @@ -58,7 +65,8 @@ impl CommandExecute for Install { }; let pg_version = format!("pg{}", pg_config.major_version()?); - let features = crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); + let features = + crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); install_extension( self.manifest_path.as_ref(), @@ -106,7 +114,12 @@ pub(crate) fn install_extension( )); } - let build_command_output = build_extension(user_manifest_path.as_ref(), user_package, is_release, &features)?; + let build_command_output = build_extension( + user_manifest_path.as_ref(), + user_package, + is_release, + &features, + )?; let build_command_bytes = build_command_output.stdout; let build_command_reader = BufReader::new(build_command_bytes.as_slice()); let build_command_stream = cargo_metadata::Message::parse_stream(build_command_reader); @@ -122,8 +135,18 @@ pub(crate) fn install_extension( { let mut dest = base_directory.clone(); dest.push(&extdir); - dest.push(&control_file.file_name().ok_or_else(|| eyre!("Could not get filename for `{}`", control_file.display()))?); - copy_file(&control_file, &dest, "control file", true, &package_manifest_path)?; + dest.push( + &control_file + .file_name() + .ok_or_else(|| eyre!("Could not get filename for `{}`", control_file.display()))?, + ); + copy_file( + &control_file, + &dest, + "control file", + true, + &package_manifest_path, + )?; } { @@ -141,7 +164,13 @@ pub(crate) fn install_extension( })?; } } - copy_file(&shlibpath, &dest, "shared library", false, &package_manifest_path)?; + copy_file( + &shlibpath, + &dest, + "shared library", + false, + &package_manifest_path, + )?; } copy_sql_files( @@ -161,7 +190,13 @@ pub(crate) fn install_extension( Ok(()) } -fn copy_file(src: &PathBuf, dest: &PathBuf, msg: &str, do_filter: bool, package_manifest_path: impl AsRef) -> eyre::Result<()> { +fn copy_file( + src: &PathBuf, + dest: &PathBuf, + msg: &str, + do_filter: bool, + package_manifest_path: impl AsRef, +) -> eyre::Result<()> { if !dest.parent().unwrap().exists() { std::fs::create_dir_all(dest.parent().unwrap()).wrap_err_with(|| { format!( @@ -216,7 +251,7 @@ pub(crate) fn build_extension( command.arg("--package"); command.arg(user_package); } - + if is_release { command.arg("--release"); } @@ -258,7 +293,11 @@ pub(crate) fn build_extension( } } -fn get_target_sql_file(manifest_path: impl AsRef, extdir: &PathBuf, base_directory: &PathBuf) -> eyre::Result { +fn get_target_sql_file( + manifest_path: impl AsRef, + extdir: &PathBuf, + base_directory: &PathBuf, +) -> eyre::Result { let mut dest = base_directory.clone(); dest.push(extdir); @@ -309,7 +348,13 @@ fn copy_sql_files( dest.push(extdir); dest.push(filename); - copy_file(&sql.path(), &dest, "extension schema upgrade file", true, &package_manifest_path)?; + copy_file( + &sql.path(), + &dest, + "extension schema upgrade file", + true, + &package_manifest_path, + )?; } } } diff --git a/cargo-pgx/src/command/mod.rs b/cargo-pgx/src/command/mod.rs index 6f9e4eac1..ed439a236 100644 --- a/cargo-pgx/src/command/mod.rs +++ b/cargo-pgx/src/command/mod.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub(crate) mod connect; pub(crate) mod get; diff --git a/cargo-pgx/src/command/new.rs b/cargo-pgx/src/command/new.rs index 7dad3dd7e..01367d869 100644 --- a/cargo-pgx/src/command/new.rs +++ b/cargo-pgx/src/command/new.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use eyre::eyre; use std::{io::Write, path::PathBuf, str::FromStr}; diff --git a/cargo-pgx/src/command/package.rs b/cargo-pgx/src/command/package.rs index 284de9513..63cb317c6 100644 --- a/cargo-pgx/src/command/package.rs +++ b/cargo-pgx/src/command/package.rs @@ -1,14 +1,20 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ command::{get::get_property, install::install_extension}, CommandExecute, }; -use eyre::{eyre, WrapErr}; use cargo_toml::Manifest; +use eyre::{eyre, WrapErr}; use pgx_utils::{get_target_dir, pg_config::PgConfig}; -use std::path::{PathBuf, Path}; +use std::path::{Path, PathBuf}; /// Create an installation package directory. #[derive(clap::Args, Debug)] @@ -44,10 +50,11 @@ impl CommandExecute for Package { let metadata = crate::metadata::metadata(&self.features, self.manifest_path.as_ref()) .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; - let package_manifest = Manifest::from_path(&package_manifest_path) - .wrap_err("Couldn't parse manifest")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; + let package_manifest = + Manifest::from_path(&package_manifest_path).wrap_err("Couldn't parse manifest")?; let pg_config = match self.pg_config { None => PgConfig::from_path(), @@ -55,14 +62,24 @@ impl CommandExecute for Package { }; let pg_version = format!("pg{}", pg_config.major_version()?); - let features = crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); - + let features = + crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); + let out_dir = if let Some(out_dir) = self.out_dir { out_dir } else { build_base_path(&pg_config, &package_manifest_path, self.debug)? }; - package_extension(self.manifest_path.as_ref(), self.package.as_ref(), &package_manifest_path, &pg_config, out_dir, self.debug, self.test, &features) + package_extension( + self.manifest_path.as_ref(), + self.package.as_ref(), + &package_manifest_path, + &pg_config, + out_dir, + self.debug, + self.test, + &features, + ) } } @@ -97,10 +114,15 @@ pub(crate) fn package_extension( ) } -fn build_base_path(pg_config: &PgConfig, manifest_path: impl AsRef, is_debug: bool) -> eyre::Result { +fn build_base_path( + pg_config: &PgConfig, + manifest_path: impl AsRef, + is_debug: bool, +) -> eyre::Result { let mut target_dir = get_target_dir()?; let pgver = pg_config.major_version()?; - let extname = get_property(manifest_path, "extname")?.ok_or(eyre!("could not determine extension name"))?; + let extname = get_property(manifest_path, "extname")? + .ok_or(eyre!("could not determine extension name"))?; target_dir.push(if is_debug { "debug" } else { "release" }); target_dir.push(format!("{}-pg{}", extname, pgver)); Ok(target_dir) diff --git a/cargo-pgx/src/command/pgx.rs b/cargo-pgx/src/command/pgx.rs index cfb9bda3a..9098b2937 100644 --- a/cargo-pgx/src/command/pgx.rs +++ b/cargo-pgx/src/command/pgx.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::CommandExecute; use owo_colors::OwoColorize; use std::path::Path; diff --git a/cargo-pgx/src/command/run.rs b/cargo-pgx/src/command/run.rs index df6916c22..539887a0f 100644 --- a/cargo-pgx/src/command/run.rs +++ b/cargo-pgx/src/command/run.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ command::{ @@ -7,14 +13,14 @@ use crate::{ }, CommandExecute, }; +use cargo_toml::Manifest; use eyre::{eyre, WrapErr}; use owo_colors::OwoColorize; use pgx_utils::{ createdb, pg_config::{PgConfig, Pgx}, }; -use cargo_toml::Manifest; -use std::{path::Path, os::unix::process::CommandExt, process::Command}; +use std::{os::unix::process::CommandExt, path::Path, process::Command}; /// Compile/install extension to a pgx-managed Postgres instance and start psql #[derive(clap::Args, Debug)] #[clap(author)] @@ -45,10 +51,11 @@ impl CommandExecute for Run { let metadata = crate::metadata::metadata(&self.features, self.manifest_path.as_ref()) .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; - let package_manifest = Manifest::from_path(&package_manifest_path) - .wrap_err("Couldn't parse manifest")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; + let package_manifest = + Manifest::from_path(&package_manifest_path).wrap_err("Couldn't parse manifest")?; let pgx = Pgx::from_config()?; @@ -62,8 +69,9 @@ impl CommandExecute for Run { } // It's actually the dbname! We should infer from the manifest. self.dbname = Some(pg_version); - let default_pg_version = crate::manifest::default_pg_version(&package_manifest) - .ok_or(eyre!("No provided `pg$VERSION` flag."))?; + let default_pg_version = + crate::manifest::default_pg_version(&package_manifest) + .ok_or(eyre!("No provided `pg$VERSION` flag."))?; (pgx.get(&default_pg_version)?, default_pg_version) } } @@ -76,11 +84,13 @@ impl CommandExecute for Run { } }; - let features = crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); + let features = + crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); let dbname = match self.dbname { Some(dbname) => dbname, - None => get_property(&package_manifest_path, "extname")?.ok_or(eyre!("could not determine extension name"))?, + None => get_property(&package_manifest_path, "extname")? + .ok_or(eyre!("could not determine extension name"))?, }; run_psql( @@ -103,7 +113,7 @@ impl CommandExecute for Run { pub(crate) fn run_psql( pg_config: &PgConfig, user_manifest_path: Option>, - user_package: Option< &String>, + user_package: Option<&String>, package_manifest_path: impl AsRef, dbname: &str, is_release: bool, @@ -114,7 +124,14 @@ pub(crate) fn run_psql( // install the extension install_extension( - user_manifest_path, user_package, package_manifest_path, pg_config, is_release, false, None, features, + user_manifest_path, + user_package, + package_manifest_path, + pg_config, + is_release, + false, + None, + features, )?; // restart postgres diff --git a/cargo-pgx/src/command/schema.rs b/cargo-pgx/src/command/schema.rs index 2fd9524e3..72edd3693 100644 --- a/cargo-pgx/src/command/schema.rs +++ b/cargo-pgx/src/command/schema.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ command::{ get::{find_control_file, get_property}, @@ -5,6 +13,7 @@ use crate::{ }, CommandExecute, }; +use cargo_toml::Manifest; use eyre::{eyre, WrapErr}; use object::Object; use owo_colors::OwoColorize; @@ -19,7 +28,6 @@ use std::{ path::{Path, PathBuf}, process::{Command, Stdio}, }; -use cargo_toml::Manifest; // Since we support extensions with `#[no_std]` extern crate alloc; use alloc::vec::Vec; @@ -66,10 +74,11 @@ impl CommandExecute for Schema { let metadata = crate::metadata::metadata(&self.features, self.manifest_path.as_ref()) .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; - let package_manifest = Manifest::from_path(&package_manifest_path) - .wrap_err("Couldn't parse manifest")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; + let package_manifest = + Manifest::from_path(&package_manifest_path).wrap_err("Couldn't parse manifest")?; let log_level = if let Ok(log_level) = std::env::var("RUST_LOG") { Some(log_level) @@ -101,7 +110,8 @@ impl CommandExecute for Schema { } }; - let features = crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); + let features = + crate::manifest::features_for_version(self.features, &package_manifest, &pg_version); generate_schema( &pg_config, @@ -181,7 +191,7 @@ pub(crate) fn generate_schema( command.arg("--manifest-path"); command.arg(user_manifest_path.as_ref()); } - + if is_release { command.arg("--release"); } diff --git a/cargo-pgx/src/command/start.rs b/cargo-pgx/src/command/start.rs index 184953e87..ab7469aee 100644 --- a/cargo-pgx/src/command/start.rs +++ b/cargo-pgx/src/command/start.rs @@ -1,18 +1,20 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::command::init::initdb; use crate::command::status::status_postgres; use crate::CommandExecute; +use cargo_toml::Manifest; use eyre::{eyre, WrapErr}; use owo_colors::OwoColorize; use pgx_utils::pg_config::{PgConfig, PgConfigSelector, Pgx}; -use std::{ - os::unix::process::CommandExt, - process::Stdio, - path::PathBuf, -}; -use cargo_toml::Manifest; +use std::{os::unix::process::CommandExt, path::PathBuf, process::Stdio}; /// Start a pgx-managed Postgres instance #[derive(clap::Args, Debug)] @@ -39,14 +41,16 @@ impl CommandExecute for Start { let pg_version = match self.pg_version { Some(s) => s, None => { - let metadata = crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) - .wrap_err("couldn't get cargo metadata")?; + let metadata = + crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) + .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; let package_manifest = Manifest::from_path(&package_manifest_path) .wrap_err("Couldn't parse manifest")?; - + crate::manifest::default_pg_version(&package_manifest) .ok_or(eyre!("no provided `pg$VERSION` flag."))? } diff --git a/cargo-pgx/src/command/status.rs b/cargo-pgx/src/command/status.rs index 7234c6cf3..0eddcdb42 100644 --- a/cargo-pgx/src/command/status.rs +++ b/cargo-pgx/src/command/status.rs @@ -1,13 +1,16 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use eyre::eyre; use owo_colors::OwoColorize; use pgx_utils::pg_config::{PgConfig, PgConfigSelector, Pgx}; -use std::{ - process::Stdio, - path::PathBuf, -}; +use std::{path::PathBuf, process::Stdio}; use crate::CommandExecute; diff --git a/cargo-pgx/src/command/stop.rs b/cargo-pgx/src/command/stop.rs index 90330a201..7b8984b6b 100644 --- a/cargo-pgx/src/command/stop.rs +++ b/cargo-pgx/src/command/stop.rs @@ -1,15 +1,18 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{command::status::status_postgres, CommandExecute}; -use owo_colors::OwoColorize; -use pgx_utils::pg_config::{PgConfig, PgConfigSelector, Pgx}; use cargo_toml::Manifest; use eyre::{eyre, WrapErr}; -use std::{ - path::PathBuf, - process::Stdio -}; +use owo_colors::OwoColorize; +use pgx_utils::pg_config::{PgConfig, PgConfigSelector, Pgx}; +use std::{path::PathBuf, process::Stdio}; /// Stop a pgx-managed Postgres instance #[derive(clap::Args, Debug)] @@ -36,11 +39,13 @@ impl CommandExecute for Stop { let pg_version = match self.pg_version { Some(s) => s, None => { - let metadata = crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) - .wrap_err("couldn't get cargo metadata")?; + let metadata = + crate::metadata::metadata(&Default::default(), self.manifest_path.as_ref()) + .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; let package_manifest = Manifest::from_path(&package_manifest_path) .wrap_err("Couldn't parse manifest")?; diff --git a/cargo-pgx/src/command/test.rs b/cargo-pgx/src/command/test.rs index e6720f195..1a39f47a6 100644 --- a/cargo-pgx/src/command/test.rs +++ b/cargo-pgx/src/command/test.rs @@ -1,15 +1,21 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ + +use cargo_toml::Manifest; use eyre::{eyre, WrapErr}; use pgx_utils::{ get_target_dir, pg_config::{PgConfig, PgConfigSelector, Pgx}, }; -use cargo_toml::Manifest; use std::{ + path::{Path, PathBuf}, process::{Command, Stdio}, - path::{PathBuf, Path}, }; use crate::CommandExecute; @@ -48,14 +54,15 @@ impl CommandExecute for Test { #[tracing::instrument(level = "error", skip(self))] fn execute(self) -> eyre::Result<()> { let pgx = Pgx::from_config()?; - + let metadata = crate::metadata::metadata(&self.features, self.manifest_path.as_ref()) .wrap_err("couldn't get cargo metadata")?; crate::metadata::validate(&metadata)?; - let package_manifest_path = crate::manifest::manifest_path(&metadata, self.package.as_ref()) - .wrap_err("Couldn't get manifest path")?; - let package_manifest = Manifest::from_path(&package_manifest_path) - .wrap_err("Couldn't parse manifest")?; + let package_manifest_path = + crate::manifest::manifest_path(&metadata, self.package.as_ref()) + .wrap_err("Couldn't get manifest path")?; + let package_manifest = + Manifest::from_path(&package_manifest_path).wrap_err("Couldn't parse manifest")?; let pg_version = match self.pg_version { Some(ref s) => s.clone(), @@ -63,7 +70,6 @@ impl CommandExecute for Test { .ok_or(eyre!("No provided `pg$VERSION` flag."))?, }; - for pg_config in pgx.iter(PgConfigSelector::new(&pg_version)) { let mut testname = self.testname.clone(); let pg_config = match pg_config { @@ -83,7 +89,11 @@ impl CommandExecute for Test { }; let pg_version = format!("pg{}", pg_config.major_version()?); - let features = crate::manifest::features_for_version(self.features.clone(), &package_manifest, &pg_version); + let features = crate::manifest::features_for_version( + self.features.clone(), + &package_manifest, + &pg_version, + ); test_extension( pg_config, diff --git a/cargo-pgx/src/main.rs b/cargo-pgx/src/main.rs index c74ef5cb2..0ae74adf5 100644 --- a/cargo-pgx/src/main.rs +++ b/cargo-pgx/src/main.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ mod command; mod manifest; diff --git a/cargo-pgx/src/manifest.rs b/cargo-pgx/src/manifest.rs index cb9542eb2..201ec9309 100644 --- a/cargo-pgx/src/manifest.rs +++ b/cargo-pgx/src/manifest.rs @@ -1,21 +1,34 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use cargo_metadata::Metadata; use cargo_toml::Manifest; use eyre::eyre; -use std::path::PathBuf; use pgx_utils::SUPPORTED_MAJOR_VERSIONS; +use std::path::PathBuf; #[tracing::instrument(skip_all)] -pub(crate) fn manifest_path(metadata: &Metadata, package_name: Option<&String>) -> eyre::Result { +pub(crate) fn manifest_path( + metadata: &Metadata, + package_name: Option<&String>, +) -> eyre::Result { let manifest_path = if let Some(package_name) = package_name { - let found = metadata.packages.iter() + let found = metadata + .packages + .iter() .find(|v| v.name == *package_name) .ok_or_else(|| eyre!("Could not find package `{}`", package_name))?; tracing::debug!(manifest_path = %found.manifest_path, "Found workspace package"); found.manifest_path.clone().into_std_path_buf() } else { - let root = metadata - .root_package() - .ok_or(eyre!("`pgx` requires a root package in a workspace when `--package` is not specified."))?; + let root = metadata.root_package().ok_or(eyre!( + "`pgx` requires a root package in a workspace when `--package` is not specified." + ))?; tracing::debug!(manifest_path = %root.manifest_path, "Found root package"); root.manifest_path.clone().into_std_path_buf() }; diff --git a/cargo-pgx/src/metadata.rs b/cargo-pgx/src/metadata.rs index a37807c8a..87246db25 100644 --- a/cargo-pgx/src/metadata.rs +++ b/cargo-pgx/src/metadata.rs @@ -1,9 +1,20 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use cargo_metadata::{Metadata, MetadataCommand}; use eyre::eyre; use semver::{Version, VersionReq}; use std::path::Path; -pub fn metadata(features: &clap_cargo::Features, manifest_path: Option>) -> eyre::Result { +pub fn metadata( + features: &clap_cargo::Features, + manifest_path: Option>, +) -> eyre::Result { let mut metadata_command = MetadataCommand::new(); if let Some(manifest_path) = manifest_path { metadata_command.manifest_path(manifest_path.as_ref().to_owned()); diff --git a/nix/templates/default/src/lib.rs b/nix/templates/default/src/lib.rs index 44c150b02..c3c42f523 100644 --- a/nix/templates/default/src/lib.rs +++ b/nix/templates/default/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; pg_module_magic!(); diff --git a/pgx-examples/aggregate/src/lib.rs b/pgx-examples/aggregate/src/lib.rs index c37e819b3..f38b7e7b2 100644 --- a/pgx-examples/aggregate/src/lib.rs +++ b/pgx-examples/aggregate/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::cstr_core::CStr; use pgx::*; use serde::{Deserialize, Serialize}; diff --git a/pgx-examples/arrays/src/lib.rs b/pgx-examples/arrays/src/lib.rs index c65306720..4dedae136 100644 --- a/pgx-examples/arrays/src/lib.rs +++ b/pgx-examples/arrays/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde::*; diff --git a/pgx-examples/bad_ideas/src/lib.rs b/pgx-examples/bad_ideas/src/lib.rs index b3ab4e5fb..72ec429fc 100644 --- a/pgx-examples/bad_ideas/src/lib.rs +++ b/pgx-examples/bad_ideas/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use std::fs::File; use std::io::Write; diff --git a/pgx-examples/bgworker/src/lib.rs b/pgx-examples/bgworker/src/lib.rs index ca77df06b..c3b23604e 100644 --- a/pgx-examples/bgworker/src/lib.rs +++ b/pgx-examples/bgworker/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::bgworkers::*; use pgx::*; use std::time::Duration; diff --git a/pgx-examples/bytea/src/lib.rs b/pgx-examples/bytea/src/lib.rs index 65982c2a6..1c8d58b5f 100644 --- a/pgx-examples/bytea/src/lib.rs +++ b/pgx-examples/bytea/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use libflate::gzip::{Decoder, Encoder}; use pgx::*; diff --git a/pgx-examples/custom_sql/sql/finalizer.sql b/pgx-examples/custom_sql/sql/finalizer.sql index e51feb645..6f1ac30f5 100644 --- a/pgx-examples/custom_sql/sql/finalizer.sql +++ b/pgx-examples/custom_sql/sql/finalizer.sql @@ -1 +1,9 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ INSERT INTO extension_sql VALUES ('finalizer'); diff --git a/pgx-examples/custom_sql/sql/multiple.sql b/pgx-examples/custom_sql/sql/multiple.sql index 2478f3268..eca36444f 100644 --- a/pgx-examples/custom_sql/sql/multiple.sql +++ b/pgx-examples/custom_sql/sql/multiple.sql @@ -1 +1,9 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ INSERT INTO extension_sql VALUES ('multiple'); diff --git a/pgx-examples/custom_sql/sql/single.sql b/pgx-examples/custom_sql/sql/single.sql index 3a93bc8e2..688e94799 100644 --- a/pgx-examples/custom_sql/sql/single.sql +++ b/pgx-examples/custom_sql/sql/single.sql @@ -1 +1,9 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ INSERT INTO extension_sql VALUES ('single'); diff --git a/pgx-examples/custom_sql/src/lib.rs b/pgx-examples/custom_sql/src/lib.rs index 5fe84f260..796f6d158 100644 --- a/pgx-examples/custom_sql/src/lib.rs +++ b/pgx-examples/custom_sql/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde::{Deserialize, Serialize}; diff --git a/pgx-examples/custom_types/src/complex.rs b/pgx-examples/custom_types/src/complex.rs index 4fcf1e0b6..6b7b2143a 100644 --- a/pgx-examples/custom_types/src/complex.rs +++ b/pgx-examples/custom_types/src/complex.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use maplit::*; use pgx::*; diff --git a/pgx-examples/custom_types/src/fixed_size.rs b/pgx-examples/custom_types/src/fixed_size.rs index bcc9ed030..e2349dd22 100644 --- a/pgx-examples/custom_types/src/fixed_size.rs +++ b/pgx-examples/custom_types/src/fixed_size.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::cstr_core::CStr; use pgx::*; use std::str::FromStr; diff --git a/pgx-examples/custom_types/src/generic_enum.rs b/pgx-examples/custom_types/src/generic_enum.rs index 547160e5a..14a1fafeb 100644 --- a/pgx-examples/custom_types/src/generic_enum.rs +++ b/pgx-examples/custom_types/src/generic_enum.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde::*; diff --git a/pgx-examples/custom_types/src/hstore_clone.rs b/pgx-examples/custom_types/src/hstore_clone.rs index 1a6d3babb..27c99aaf2 100644 --- a/pgx-examples/custom_types/src/hstore_clone.rs +++ b/pgx-examples/custom_types/src/hstore_clone.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use maplit::*; use pgx::*; diff --git a/pgx-examples/custom_types/src/lib.rs b/pgx-examples/custom_types/src/lib.rs index 5f55609ea..5e20ae6b4 100644 --- a/pgx-examples/custom_types/src/lib.rs +++ b/pgx-examples/custom_types/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-examples/errors/src/lib.rs b/pgx-examples/errors/src/lib.rs index 8000b560b..c962f125d 100644 --- a/pgx-examples/errors/src/lib.rs +++ b/pgx-examples/errors/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-examples/nostd/src/lib.rs b/pgx-examples/nostd/src/lib.rs index f4edd9662..5f35fac5a 100644 --- a/pgx-examples/nostd/src/lib.rs +++ b/pgx-examples/nostd/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! This exists just to make sure we can compile various things under `#![no_std]` #![no_std] diff --git a/pgx-examples/operators/src/derived.rs b/pgx-examples/operators/src/derived.rs index d1d8f8dd3..6809b79b5 100644 --- a/pgx-examples/operators/src/derived.rs +++ b/pgx-examples/operators/src/derived.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde::{Deserialize, Serialize}; diff --git a/pgx-examples/operators/src/lib.rs b/pgx-examples/operators/src/lib.rs index 218fa8e3b..7560b0a11 100644 --- a/pgx-examples/operators/src/lib.rs +++ b/pgx-examples/operators/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde::{Deserialize, Serialize}; diff --git a/pgx-examples/schemas/src/lib.rs b/pgx-examples/schemas/src/lib.rs index 6090691f6..38803dc44 100644 --- a/pgx-examples/schemas/src/lib.rs +++ b/pgx-examples/schemas/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ /// All top-level pgx objects, **regardless** of the ".rs" file they're defined in, are created /// in the schema determined by `CREATE EXTENSION`. It could be `public` (the default), or a /// user-specified schema. We have no idea what that is. diff --git a/pgx-examples/shmem/src/lib.rs b/pgx-examples/shmem/src/lib.rs index 20781d2d7..0399882a0 100644 --- a/pgx-examples/shmem/src/lib.rs +++ b/pgx-examples/shmem/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde::*; use std::iter::Iterator; diff --git a/pgx-examples/spi/src/lib.rs b/pgx-examples/spi/src/lib.rs index fb8df56b5..401902c5a 100644 --- a/pgx-examples/spi/src/lib.rs +++ b/pgx-examples/spi/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; pg_module_magic!(); diff --git a/pgx-examples/srf/src/lib.rs b/pgx-examples/srf/src/lib.rs index 86672bec5..7f8ac0a77 100644 --- a/pgx-examples/srf/src/lib.rs +++ b/pgx-examples/srf/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-examples/strings/src/lib.rs b/pgx-examples/strings/src/lib.rs index 09cac8573..ecd139245 100644 --- a/pgx-examples/strings/src/lib.rs +++ b/pgx-examples/strings/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-examples/triggers/src/lib.rs b/pgx-examples/triggers/src/lib.rs index b2b83aa02..17c5b951e 100644 --- a/pgx-examples/triggers/src/lib.rs +++ b/pgx-examples/triggers/src/lib.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; pg_module_magic!(); diff --git a/pgx-macros/src/lib.rs b/pgx-macros/src/lib.rs index eecacb8f1..4ca631db5 100644 --- a/pgx-macros/src/lib.rs +++ b/pgx-macros/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ extern crate proc_macro; diff --git a/pgx-macros/src/operators.rs b/pgx-macros/src/operators.rs index 50ffeb6a7..8c2594ea3 100644 --- a/pgx-macros/src/operators.rs +++ b/pgx-macros/src/operators.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx_utils::{ operator_common::*, sql_entity_graph::{PostgresHash, PostgresOrd}, diff --git a/pgx-macros/src/rewriter.rs b/pgx-macros/src/rewriter.rs index 8fd372510..f317ff464 100644 --- a/pgx-macros/src/rewriter.rs +++ b/pgx-macros/src/rewriter.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ extern crate proc_macro; diff --git a/pgx-macros/static/demo.sql b/pgx-macros/static/demo.sql index cc6393518..c2e0f37ed 100644 --- a/pgx-macros/static/demo.sql +++ b/pgx-macros/static/demo.sql @@ -1,2 +1,13 @@ --- Example for extension_sql_file doctest. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ +/* +Copyright 2019-2022 ZomboDB, LLC and Technology Concepts & Design, Inc. . All rights reserved. Use of +this source code is governed by the MIT license that can be found in the LICENSE file.*//*Copyright 2019-2022 ZomboDB, LLC and Technology Concepts & Design, Inc. . All rights reserved. Use of +this source code is governed by the MIT license that can be found in the LICENSE file.*/-- Example for extension_sql_file doctest. SELECT true; diff --git a/pgx-pg-sys/build.rs b/pgx-pg-sys/build.rs index e8126b961..c75ec2676 100644 --- a/pgx-pg-sys/build.rs +++ b/pgx-pg-sys/build.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ extern crate build_deps; diff --git a/pgx-pg-sys/cshim/Makefile b/pgx-pg-sys/cshim/Makefile index 0b569cef5..0a046c103 100644 --- a/pgx-pg-sys/cshim/Makefile +++ b/pgx-pg-sys/cshim/Makefile @@ -1,5 +1,11 @@ -# Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -# governed by the MIT license that can be found in the LICENSE file. +# Portions Copyright 2019-2021 ZomboDB, LLC. +# Portions Copyright 2021-2022 Technology Concepts & Design, Inc. +# +# +# All rights reserved. +# +# Use of this source code is governed by the MIT license that can be found in +# the LICENSE file. MODULE_big = pgx-cshim-${PG_TARGET_VERSION} diff --git a/pgx-pg-sys/cshim/pgx-cshim.c b/pgx-pg-sys/cshim/pgx-cshim.c index 6845e4770..6952812f7 100644 --- a/pgx-pg-sys/cshim/pgx-cshim.c +++ b/pgx-pg-sys/cshim/pgx-cshim.c @@ -1,8 +1,11 @@ /* - * Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is - * governed by the MIT license that can be found in the LICENSE file. - */ +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #include "postgres.h" #define IS_PG_10 (PG_VERSION_NUM >= 100000 && PG_VERSION_NUM < 110000) diff --git a/pgx-pg-sys/include/pg10.h b/pgx-pg-sys/include/pg10.h index 9c843351c..054516fe8 100644 --- a/pgx-pg-sys/include/pg10.h +++ b/pgx-pg-sys/include/pg10.h @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #include #define USE_STDBOOL 1 diff --git a/pgx-pg-sys/include/pg11.h b/pgx-pg-sys/include/pg11.h index ce8666613..057fc9995 100644 --- a/pgx-pg-sys/include/pg11.h +++ b/pgx-pg-sys/include/pg11.h @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #include "postgres.h" #include "pg_config.h" #include "funcapi.h" diff --git a/pgx-pg-sys/include/pg12.h b/pgx-pg-sys/include/pg12.h index 86ab457ad..13a8f2179 100644 --- a/pgx-pg-sys/include/pg12.h +++ b/pgx-pg-sys/include/pg12.h @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #include "postgres.h" #include "pg_config.h" #include "funcapi.h" diff --git a/pgx-pg-sys/include/pg13.h b/pgx-pg-sys/include/pg13.h index 10db5f2de..72bf536a5 100644 --- a/pgx-pg-sys/include/pg13.h +++ b/pgx-pg-sys/include/pg13.h @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #include "postgres.h" #include "pg_config.h" #include "funcapi.h" diff --git a/pgx-pg-sys/include/pg14.h b/pgx-pg-sys/include/pg14.h index 10db5f2de..72bf536a5 100644 --- a/pgx-pg-sys/include/pg14.h +++ b/pgx-pg-sys/include/pg14.h @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #include "postgres.h" #include "pg_config.h" #include "funcapi.h" diff --git a/pgx-pg-sys/src/lib.rs b/pgx-pg-sys/src/lib.rs index b75089d6d..63128f0e2 100644 --- a/pgx-pg-sys/src/lib.rs +++ b/pgx-pg-sys/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ // // we allow improper_ctypes just to eliminate these warnings: diff --git a/pgx-pg-sys/src/pg10.rs b/pgx-pg-sys/src/pg10.rs index cc0b83798..d070d0c68 100644 --- a/pgx-pg-sys/src/pg10.rs +++ b/pgx-pg-sys/src/pg10.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate as pg_sys; use crate::PgNode; use pgx_macros::*; diff --git a/pgx-pg-sys/src/pg10_oids.rs b/pgx-pg-sys/src/pg10_oids.rs index 9b8d33dc9..6f718ee04 100644 --- a/pgx-pg-sys/src/pg10_oids.rs +++ b/pgx-pg-sys/src/pg10_oids.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[derive(Copy, Clone, Eq, PartialEq, Hash, Ord, PartialOrd, Debug)] pub enum PgBuiltInOids { BOOLOID = crate::BOOLOID as isize, diff --git a/pgx-pg-sys/src/pg11.rs b/pgx-pg-sys/src/pg11.rs index 615cf11d9..9c28625ee 100644 --- a/pgx-pg-sys/src/pg11.rs +++ b/pgx-pg-sys/src/pg11.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate as pg_sys; use crate::PgNode; use pgx_macros::*; diff --git a/pgx-pg-sys/src/pg11_oids.rs b/pgx-pg-sys/src/pg11_oids.rs index 295b92dae..b0c2e123d 100644 --- a/pgx-pg-sys/src/pg11_oids.rs +++ b/pgx-pg-sys/src/pg11_oids.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[derive(Copy, Clone, Eq, PartialEq, Hash, Ord, PartialOrd, Debug)] pub enum PgBuiltInOids { BOOLOID = crate::BOOLOID as isize, diff --git a/pgx-pg-sys/src/pg12.rs b/pgx-pg-sys/src/pg12.rs index 1c47ee350..6d7c26dcf 100644 --- a/pgx-pg-sys/src/pg12.rs +++ b/pgx-pg-sys/src/pg12.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate as pg_sys; use crate::PgNode; use pgx_macros::*; diff --git a/pgx-pg-sys/src/pg12_oids.rs b/pgx-pg-sys/src/pg12_oids.rs index de446c3a6..2e708c1c4 100644 --- a/pgx-pg-sys/src/pg12_oids.rs +++ b/pgx-pg-sys/src/pg12_oids.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[derive(Copy, Clone, Eq, PartialEq, Hash, Ord, PartialOrd, Debug)] pub enum PgBuiltInOids { HEAP_TABLE_AM_HANDLER_OID = crate::HEAP_TABLE_AM_HANDLER_OID as isize, diff --git a/pgx-pg-sys/src/pg13.rs b/pgx-pg-sys/src/pg13.rs index 4d00eda1a..90957757e 100644 --- a/pgx-pg-sys/src/pg13.rs +++ b/pgx-pg-sys/src/pg13.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate as pg_sys; use crate::PgNode; use pgx_macros::*; diff --git a/pgx-pg-sys/src/pg13_oids.rs b/pgx-pg-sys/src/pg13_oids.rs index e5901c13a..231cd3598 100644 --- a/pgx-pg-sys/src/pg13_oids.rs +++ b/pgx-pg-sys/src/pg13_oids.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[derive(Copy, Clone, Eq, PartialEq, Hash, Ord, PartialOrd, Debug)] pub enum PgBuiltInOids { BOOLOID = crate::BOOLOID as isize, diff --git a/pgx-pg-sys/src/pg14.rs b/pgx-pg-sys/src/pg14.rs index 3e47516e9..27819d33a 100644 --- a/pgx-pg-sys/src/pg14.rs +++ b/pgx-pg-sys/src/pg14.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate as pg_sys; use crate::PgNode; use pgx_macros::*; diff --git a/pgx-pg-sys/src/pg14_oids.rs b/pgx-pg-sys/src/pg14_oids.rs index c26b149d4..d347aefab 100644 --- a/pgx-pg-sys/src/pg14_oids.rs +++ b/pgx-pg-sys/src/pg14_oids.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[derive(Copy, Clone, Eq, PartialEq, Hash, Ord, PartialOrd, Debug)] pub enum PgBuiltInOids { BOOLOID = crate::BOOLOID as isize, diff --git a/pgx-pg-sys/src/submodules/guard.rs b/pgx-pg-sys/src/submodules/guard.rs index d5d309dfa..fe384b36f 100644 --- a/pgx-pg-sys/src/submodules/guard.rs +++ b/pgx-pg-sys/src/submodules/guard.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #![allow(non_snake_case)] diff --git a/pgx-pg-sys/src/submodules/mod.rs b/pgx-pg-sys/src/submodules/mod.rs index 4f9671bda..78d7d7602 100644 --- a/pgx-pg-sys/src/submodules/mod.rs +++ b/pgx-pg-sys/src/submodules/mod.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod guard; mod oids; diff --git a/pgx-pg-sys/src/submodules/oids.rs b/pgx-pg-sys/src/submodules/oids.rs index ff85c23ef..1e163f687 100644 --- a/pgx-pg-sys/src/submodules/oids.rs +++ b/pgx-pg-sys/src/submodules/oids.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #![allow(non_camel_case_types)] use crate as pg_sys; diff --git a/pgx-pg-sys/src/submodules/tupdesc.rs b/pgx-pg-sys/src/submodules/tupdesc.rs index ee42403cb..7d123066b 100644 --- a/pgx-pg-sys/src/submodules/tupdesc.rs +++ b/pgx-pg-sys/src/submodules/tupdesc.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Provides helper implementations for various `TupleDesc`-related structs use crate::{name_data_to_str, PgOid}; diff --git a/pgx-pg-sys/src/submodules/utils.rs b/pgx-pg-sys/src/submodules/utils.rs index 6f2ffb8de..4a9eb8607 100644 --- a/pgx-pg-sys/src/submodules/utils.rs +++ b/pgx-pg-sys/src/submodules/utils.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! General utility functions use crate as pg_sys; diff --git a/pgx-tests/src/framework.rs b/pgx-tests/src/framework.rs index eff1289bc..4c2b35633 100644 --- a/pgx-tests/src/framework.rs +++ b/pgx-tests/src/framework.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use std::process::{Command, Stdio}; @@ -258,7 +264,7 @@ fn install_extension() -> eyre::Result<()> { .stdout(Stdio::inherit()) .stderr(Stdio::inherit()) .env("CARGO_TARGET_DIR", get_target_dir()?); - + if let Ok(manifest_path) = std::env::var("PGX_MANIFEST_PATH") { command.arg("--manifest-path"); command.arg(manifest_path); diff --git a/pgx-tests/src/lib.rs b/pgx-tests/src/lib.rs index a9974ef7d..c2cdc0dd5 100644 --- a/pgx-tests/src/lib.rs +++ b/pgx-tests/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ mod framework; #[cfg(any(test, feature = "pg_test"))] diff --git a/pgx-tests/src/tests/aggregate_tests.rs b/pgx-tests/src/tests/aggregate_tests.rs index aca78b168..195173b60 100644 --- a/pgx-tests/src/tests/aggregate_tests.rs +++ b/pgx-tests/src/tests/aggregate_tests.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde::{Deserialize, Serialize}; use std::collections::HashSet; diff --git a/pgx-tests/src/tests/anyarray_tests.rs b/pgx-tests/src/tests/anyarray_tests.rs index df9e43924..2ac528e8e 100644 --- a/pgx-tests/src/tests/anyarray_tests.rs +++ b/pgx-tests/src/tests/anyarray_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-tests/src/tests/array_tests.rs b/pgx-tests/src/tests/array_tests.rs index ed5a6cd9d..317f3182a 100644 --- a/pgx-tests/src/tests/array_tests.rs +++ b/pgx-tests/src/tests/array_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use serde_json::*; diff --git a/pgx-tests/src/tests/bytea_tests.rs b/pgx-tests/src/tests/bytea_tests.rs index c70a003c0..8195c120b 100644 --- a/pgx-tests/src/tests/bytea_tests.rs +++ b/pgx-tests/src/tests/bytea_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/cfg_tests.rs b/pgx-tests/src/tests/cfg_tests.rs index 430645604..f9e9c8eb3 100644 --- a/pgx-tests/src/tests/cfg_tests.rs +++ b/pgx-tests/src/tests/cfg_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; #[cfg(any(test, feature = "pg_test"))] diff --git a/pgx-tests/src/tests/datetime_tests.rs b/pgx-tests/src/tests/datetime_tests.rs index 4a744ad70..5ab3b9e62 100644 --- a/pgx-tests/src/tests/datetime_tests.rs +++ b/pgx-tests/src/tests/datetime_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; use std::convert::TryFrom; diff --git a/pgx-tests/src/tests/default_arg_value_tests.rs b/pgx-tests/src/tests/default_arg_value_tests.rs index 690cf3204..e6ee15705 100644 --- a/pgx-tests/src/tests/default_arg_value_tests.rs +++ b/pgx-tests/src/tests/default_arg_value_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-tests/src/tests/derive_pgtype_lifetimes.rs b/pgx-tests/src/tests/derive_pgtype_lifetimes.rs index b57691233..2155cd6a8 100644 --- a/pgx-tests/src/tests/derive_pgtype_lifetimes.rs +++ b/pgx-tests/src/tests/derive_pgtype_lifetimes.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #![allow(dead_code)] /// the purpose of this test is to just make sure this code compiles! diff --git a/pgx-tests/src/tests/enum_type_tests.rs b/pgx-tests/src/tests/enum_type_tests.rs index 9b2d92a48..f125520fa 100644 --- a/pgx-tests/src/tests/enum_type_tests.rs +++ b/pgx-tests/src/tests/enum_type_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-tests/src/tests/fcinfo_tests.rs b/pgx-tests/src/tests/fcinfo_tests.rs index e909042b9..e1944e1bd 100644 --- a/pgx-tests/src/tests/fcinfo_tests.rs +++ b/pgx-tests/src/tests/fcinfo_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-tests/src/tests/guc_tests.rs b/pgx-tests/src/tests/guc_tests.rs index 66bd87203..e67a21166 100644 --- a/pgx-tests/src/tests/guc_tests.rs +++ b/pgx-tests/src/tests/guc_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/hooks_tests.rs b/pgx-tests/src/tests/hooks_tests.rs index d3240ac66..76af18175 100644 --- a/pgx-tests/src/tests/hooks_tests.rs +++ b/pgx-tests/src/tests/hooks_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/inet_tests.rs b/pgx-tests/src/tests/inet_tests.rs index d68a09342..ec2cbddb7 100644 --- a/pgx-tests/src/tests/inet_tests.rs +++ b/pgx-tests/src/tests/inet_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/internal_tests.rs b/pgx-tests/src/tests/internal_tests.rs index ab8c77a77..aac5dede8 100644 --- a/pgx-tests/src/tests/internal_tests.rs +++ b/pgx-tests/src/tests/internal_tests.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] mod tests { diff --git a/pgx-tests/src/tests/json_tests.rs b/pgx-tests/src/tests/json_tests.rs index 28d94d6c3..784b04650 100644 --- a/pgx-tests/src/tests/json_tests.rs +++ b/pgx-tests/src/tests/json_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/lifetime_tests.rs b/pgx-tests/src/tests/lifetime_tests.rs index 7fb28d3aa..9668a43c2 100644 --- a/pgx-tests/src/tests/lifetime_tests.rs +++ b/pgx-tests/src/tests/lifetime_tests.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! This file exists just to ensure the code within compiles use pgx::*; use serde::{Deserialize, Serialize}; diff --git a/pgx-tests/src/tests/log_tests.rs b/pgx-tests/src/tests/log_tests.rs index bbc9d8836..afadcc5ce 100644 --- a/pgx-tests/src/tests/log_tests.rs +++ b/pgx-tests/src/tests/log_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/memcxt_tests.rs b/pgx-tests/src/tests/memcxt_tests.rs index 7748ea0f0..fbd2fd4ab 100644 --- a/pgx-tests/src/tests/memcxt_tests.rs +++ b/pgx-tests/src/tests/memcxt_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/mod.rs b/pgx-tests/src/tests/mod.rs index 56b0f71f4..efcdf86b2 100644 --- a/pgx-tests/src/tests/mod.rs +++ b/pgx-tests/src/tests/mod.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ mod aggregate_tests; mod anyarray_tests; diff --git a/pgx-tests/src/tests/name_tests.rs b/pgx-tests/src/tests/name_tests.rs index 41f600a19..25072cffd 100644 --- a/pgx-tests/src/tests/name_tests.rs +++ b/pgx-tests/src/tests/name_tests.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; #[pg_extern(name = "renamed_func")] diff --git a/pgx-tests/src/tests/numeric_tests.rs b/pgx-tests/src/tests/numeric_tests.rs index 0c20fecc4..117244d63 100644 --- a/pgx-tests/src/tests/numeric_tests.rs +++ b/pgx-tests/src/tests/numeric_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/pg_extern_tests.rs b/pgx-tests/src/tests/pg_extern_tests.rs index cddcde9ea..d1ed30305 100644 --- a/pgx-tests/src/tests/pg_extern_tests.rs +++ b/pgx-tests/src/tests/pg_extern_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-tests/src/tests/pg_try_tests.rs b/pgx-tests/src/tests/pg_try_tests.rs index efff8d34f..7e4bf877e 100644 --- a/pgx-tests/src/tests/pg_try_tests.rs +++ b/pgx-tests/src/tests/pg_try_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-tests/src/tests/pgbox_tests.rs b/pgx-tests/src/tests/pgbox_tests.rs index d4909b9f0..8f03b594f 100644 --- a/pgx-tests/src/tests/pgbox_tests.rs +++ b/pgx-tests/src/tests/pgbox_tests.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] mod tests { diff --git a/pgx-tests/src/tests/postgres_type_tests.rs b/pgx-tests/src/tests/postgres_type_tests.rs index c5cc3e07b..13bea5019 100644 --- a/pgx-tests/src/tests/postgres_type_tests.rs +++ b/pgx-tests/src/tests/postgres_type_tests.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::cstr_core::CStr; use pgx::*; use serde::{Deserialize, Serialize}; diff --git a/pgx-tests/src/tests/schema_tests.rs b/pgx-tests/src/tests/schema_tests.rs index ade407b1b..258f6cb0f 100644 --- a/pgx-tests/src/tests/schema_tests.rs +++ b/pgx-tests/src/tests/schema_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/spi_tests.rs b/pgx-tests/src/tests/spi_tests.rs index de5af85f8..ee0219eb2 100644 --- a/pgx-tests/src/tests/spi_tests.rs +++ b/pgx-tests/src/tests/spi_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/srf_tests.rs b/pgx-tests/src/tests/srf_tests.rs index e589e0584..d7edc6b5b 100644 --- a/pgx-tests/src/tests/srf_tests.rs +++ b/pgx-tests/src/tests/srf_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; diff --git a/pgx-tests/src/tests/struct_type_tests.rs b/pgx-tests/src/tests/struct_type_tests.rs index f6a992ecd..ee8e4ffee 100644 --- a/pgx-tests/src/tests/struct_type_tests.rs +++ b/pgx-tests/src/tests/struct_type_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::stringinfo::StringInfo; use pgx::*; diff --git a/pgx-tests/src/tests/uuid_tests.rs b/pgx-tests/src/tests/uuid_tests.rs index b37bd4c63..9b7506798 100644 --- a/pgx-tests/src/tests/uuid_tests.rs +++ b/pgx-tests/src/tests/uuid_tests.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use pgx::*; pub const TEST_UUID_V4: UuidBytes = [ diff --git a/pgx-tests/src/tests/variadic_tests.rs b/pgx-tests/src/tests/variadic_tests.rs index da8774bd8..4ddbfd5d5 100644 --- a/pgx-tests/src/tests/variadic_tests.rs +++ b/pgx-tests/src/tests/variadic_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[pgx::pg_schema] mod test { diff --git a/pgx-tests/src/tests/xact_callback_tests.rs b/pgx-tests/src/tests/xact_callback_tests.rs index e988d555e..e7d2da753 100644 --- a/pgx-tests/src/tests/xact_callback_tests.rs +++ b/pgx-tests/src/tests/xact_callback_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-tests/src/tests/xid64_tests.rs b/pgx-tests/src/tests/xid64_tests.rs index d56b6d065..eee8ff9fe 100644 --- a/pgx-tests/src/tests/xid64_tests.rs +++ b/pgx-tests/src/tests/xid64_tests.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ #[cfg(any(test, feature = "pg_test"))] #[pgx::pg_schema] diff --git a/pgx-utils/src/lib.rs b/pgx-utils/src/lib.rs index 7070c7217..14705dda0 100644 --- a/pgx-utils/src/lib.rs +++ b/pgx-utils/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_config::PgConfig, sql_entity_graph::PositioningRef}; use eyre::{eyre, WrapErr}; diff --git a/pgx-utils/src/operator_common.rs b/pgx-utils/src/operator_common.rs index 663093c97..49878e32c 100644 --- a/pgx-utils/src/operator_common.rs +++ b/pgx-utils/src/operator_common.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use proc_macro2::Ident; use quote::quote; diff --git a/pgx-utils/src/pg_config.rs b/pgx-utils/src/pg_config.rs index 8c7ae82c1..3d5456a0e 100644 --- a/pgx-utils/src/pg_config.rs +++ b/pgx-utils/src/pg_config.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Wrapper around Postgres' `pg_config` command-line tool use eyre::{eyre, WrapErr}; use owo_colors::OwoColorize; diff --git a/pgx-utils/src/pgx_pg_sys_stub/mod.rs b/pgx-utils/src/pgx_pg_sys_stub/mod.rs index d94060de6..3fc0ca25b 100644 --- a/pgx-utils/src/pgx_pg_sys_stub/mod.rs +++ b/pgx-utils/src/pgx_pg_sys_stub/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use std::{collections::HashSet, fs::File, io::Write, path::Path}; use syn::{parse_quote, Ident, Item}; diff --git a/pgx-utils/src/sql_entity_graph/aggregate/aggregate_type.rs b/pgx-utils/src/sql_entity_graph/aggregate/aggregate_type.rs index b26eed6e4..eb20779ca 100644 --- a/pgx-utils/src/sql_entity_graph/aggregate/aggregate_type.rs +++ b/pgx-utils/src/sql_entity_graph/aggregate/aggregate_type.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use super::get_pgx_attr_macro; use crate::sql_entity_graph::NameMacro; diff --git a/pgx-utils/src/sql_entity_graph/aggregate/entity.rs b/pgx-utils/src/sql_entity_graph/aggregate/entity.rs index 098d28480..64cd1f5a7 100644 --- a/pgx-utils/src/sql_entity_graph/aggregate/entity.rs +++ b/pgx-utils/src/sql_entity_graph/aggregate/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{ aggregate::options::{FinalizeModify, ParallelOption}, pgx_sql::PgxSql, diff --git a/pgx-utils/src/sql_entity_graph/aggregate/maybe_variadic_type.rs b/pgx-utils/src/sql_entity_graph/aggregate/maybe_variadic_type.rs index 711913648..22847686c 100644 --- a/pgx-utils/src/sql_entity_graph/aggregate/maybe_variadic_type.rs +++ b/pgx-utils/src/sql_entity_graph/aggregate/maybe_variadic_type.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use super::get_pgx_attr_macro; use crate::sql_entity_graph::pg_extern::NameMacro; diff --git a/pgx-utils/src/sql_entity_graph/aggregate/mod.rs b/pgx-utils/src/sql_entity_graph/aggregate/mod.rs index b9b633ce8..49b4f7fb9 100644 --- a/pgx-utils/src/sql_entity_graph/aggregate/mod.rs +++ b/pgx-utils/src/sql_entity_graph/aggregate/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ mod aggregate_type; pub(crate) mod entity; mod maybe_variadic_type; diff --git a/pgx-utils/src/sql_entity_graph/aggregate/options.rs b/pgx-utils/src/sql_entity_graph/aggregate/options.rs index 67a3e13c8..c77208bf8 100644 --- a/pgx-utils/src/sql_entity_graph/aggregate/options.rs +++ b/pgx-utils/src/sql_entity_graph/aggregate/options.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{PgxSql, ToSql}; /// Corresponds to the `PARALLEL` and `MFINALFUNC_MODIFY` in [`CREATE AGGREGATE`](https://www.postgresql.org/docs/current/sql-createaggregate.html). diff --git a/pgx-utils/src/sql_entity_graph/control_file.rs b/pgx-utils/src/sql_entity_graph/control_file.rs index 0410b539c..c854e89a1 100644 --- a/pgx-utils/src/sql_entity_graph/control_file.rs +++ b/pgx-utils/src/sql_entity_graph/control_file.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use super::{SqlGraphEntity, SqlGraphIdentifier, ToSql}; use core::convert::TryFrom; use std::collections::HashMap; diff --git a/pgx-utils/src/sql_entity_graph/extension_sql/entity.rs b/pgx-utils/src/sql_entity_graph/extension_sql/entity.rs index cc751d5d1..ca89022dc 100644 --- a/pgx-utils/src/sql_entity_graph/extension_sql/entity.rs +++ b/pgx-utils/src/sql_entity_graph/extension_sql/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{ extension_sql::SqlDeclared, pgx_sql::PgxSql, positioning_ref::PositioningRef, to_sql::ToSql, SqlGraphEntity, SqlGraphIdentifier, diff --git a/pgx-utils/src/sql_entity_graph/extension_sql/mod.rs b/pgx-utils/src/sql_entity_graph/extension_sql/mod.rs index e3933ede2..f2d704972 100644 --- a/pgx-utils/src/sql_entity_graph/extension_sql/mod.rs +++ b/pgx-utils/src/sql_entity_graph/extension_sql/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod entity; use crate::sql_entity_graph::positioning_ref::PositioningRef; diff --git a/pgx-utils/src/sql_entity_graph/mapping.rs b/pgx-utils/src/sql_entity_graph/mapping.rs index 4a177a9fa..d44f15c9c 100644 --- a/pgx-utils/src/sql_entity_graph/mapping.rs +++ b/pgx-utils/src/sql_entity_graph/mapping.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use core::any::TypeId; /// A mapping from a Rust type to a SQL type, with a `TypeId`. diff --git a/pgx-utils/src/sql_entity_graph/mod.rs b/pgx-utils/src/sql_entity_graph/mod.rs index c693a75fd..107f3b71b 100644 --- a/pgx-utils/src/sql_entity_graph/mod.rs +++ b/pgx-utils/src/sql_entity_graph/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub(crate) mod aggregate; pub(crate) mod control_file; pub(crate) mod extension_sql; diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/argument.rs b/pgx-utils/src/sql_entity_graph/pg_extern/argument.rs index 8c7a4f751..7a6017b04 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/argument.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/argument.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use std::ops::Deref; use crate::anonymonize_lifetimes; diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/attribute.rs b/pgx-utils/src/sql_entity_graph/pg_extern/attribute.rs index 10d8b9e43..120546f86 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/attribute.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/attribute.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{positioning_ref::PositioningRef, to_sql::ToSqlConfig}; use proc_macro2::{Span, TokenStream as TokenStream2}; use quote::{quote, ToTokens, TokenStreamExt}; diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/entity/argument.rs b/pgx-utils/src/sql_entity_graph/pg_extern/entity/argument.rs index cdef27ccc..b3ee6e0f6 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/entity/argument.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/entity/argument.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::SqlGraphIdentifier; /// The output of a [`PgExternArgument`](crate::sql_entity_graph::PgExternArgument) from `quote::ToTokens::to_tokens`. diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/entity/mod.rs b/pgx-utils/src/sql_entity_graph/pg_extern/entity/mod.rs index e4f0d315b..854c0fc2d 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/entity/mod.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/entity/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ mod argument; mod operator; mod returning; diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/entity/operator.rs b/pgx-utils/src/sql_entity_graph/pg_extern/entity/operator.rs index 9e68c9360..09e6a7912 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/entity/operator.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/entity/operator.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use serde::{Deserialize, Serialize}; /// The output of a [`PgOperator`](crate::sql_entity_graph::PgOperator) from `quote::ToTokens::to_tokens`. diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/entity/returning.rs b/pgx-utils/src/sql_entity_graph/pg_extern/entity/returning.rs index adc1395c2..db1c67c32 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/entity/returning.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/entity/returning.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use core::any::TypeId; #[derive(Debug, Clone, Hash, PartialEq, Eq, PartialOrd, Ord)] diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/mod.rs b/pgx-utils/src/sql_entity_graph/pg_extern/mod.rs index 65c8a115e..2b8836506 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/mod.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ mod argument; mod attribute; pub mod entity; diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/operator.rs b/pgx-utils/src/sql_entity_graph/pg_extern/operator.rs index a4e71f6ad..63975f172 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/operator.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/operator.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use proc_macro2::TokenStream as TokenStream2; use quote::{quote, ToTokens, TokenStreamExt}; use syn::parse::{Parse, ParseBuffer}; diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/returning.rs b/pgx-utils/src/sql_entity_graph/pg_extern/returning.rs index 8587fdde9..ed6b1dfc1 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/returning.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/returning.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{anonymonize_lifetimes, anonymonize_lifetimes_in_type_path}; use eyre::eyre; use proc_macro2::{Ident, Span, TokenStream as TokenStream2}; diff --git a/pgx-utils/src/sql_entity_graph/pg_extern/search_path.rs b/pgx-utils/src/sql_entity_graph/pg_extern/search_path.rs index b087e1afb..6c2c5a449 100644 --- a/pgx-utils/src/sql_entity_graph/pg_extern/search_path.rs +++ b/pgx-utils/src/sql_entity_graph/pg_extern/search_path.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use proc_macro2::TokenStream as TokenStream2; use quote::{quote, ToTokens}; use syn::{ diff --git a/pgx-utils/src/sql_entity_graph/pgx_attribute.rs b/pgx-utils/src/sql_entity_graph/pgx_attribute.rs index 3fcf3faee..1ae8be0a3 100644 --- a/pgx-utils/src/sql_entity_graph/pgx_attribute.rs +++ b/pgx-utils/src/sql_entity_graph/pgx_attribute.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use syn::parse::{Parse, ParseStream}; use syn::{parenthesized, punctuated::Punctuated}; use syn::{token, Token}; diff --git a/pgx-utils/src/sql_entity_graph/pgx_sql.rs b/pgx-utils/src/sql_entity_graph/pgx_sql.rs index 163de5dfe..94302ea01 100644 --- a/pgx-utils/src/sql_entity_graph/pgx_sql.rs +++ b/pgx-utils/src/sql_entity_graph/pgx_sql.rs @@ -1,9 +1,17 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use eyre::{eyre, WrapErr}; use std::{any::TypeId, collections::HashMap, fmt::Debug, path::Path}; +use owo_colors::{OwoColorize, XtermColors}; use petgraph::{dot::Dot, graph::NodeIndex, stable_graph::StableGraph}; use tracing::instrument; -use owo_colors::{OwoColorize, XtermColors}; use crate::sql_entity_graph::{ aggregate::entity::PgAggregateEntity, @@ -271,7 +279,11 @@ impl PgxSql { if style.foreground.a == 0x01 { write!(*out, "{}", content)?; } else { - write!(*out, "{}", content.color(XtermColors::from(style.foreground.r)))?; + write!( + *out, + "{}", + content.color(XtermColors::from(style.foreground.r)) + )?; } } write!(*out, "\x1b[0m")?; diff --git a/pgx-utils/src/sql_entity_graph/positioning_ref.rs b/pgx-utils/src/sql_entity_graph/positioning_ref.rs index 662023e27..ff292db2d 100644 --- a/pgx-utils/src/sql_entity_graph/positioning_ref.rs +++ b/pgx-utils/src/sql_entity_graph/positioning_ref.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use quote::{quote, ToTokens}; use std::fmt::Display; use syn::parse::{Parse, ParseStream}; diff --git a/pgx-utils/src/sql_entity_graph/postgres_enum/entity.rs b/pgx-utils/src/sql_entity_graph/postgres_enum/entity.rs index cfe99f012..a43fd4bf8 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_enum/entity.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_enum/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{ mapping::RustSqlMapping, pgx_sql::PgxSql, diff --git a/pgx-utils/src/sql_entity_graph/postgres_enum/mod.rs b/pgx-utils/src/sql_entity_graph/postgres_enum/mod.rs index 2b6fbd560..e16599bc3 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_enum/mod.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_enum/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod entity; use crate::sql_entity_graph::ToSqlConfig; diff --git a/pgx-utils/src/sql_entity_graph/postgres_hash/entity.rs b/pgx-utils/src/sql_entity_graph/postgres_hash/entity.rs index 405dcef99..50ee16d39 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_hash/entity.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_hash/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{ pgx_sql::PgxSql, to_sql::{entity::ToSqlConfigEntity, ToSql}, diff --git a/pgx-utils/src/sql_entity_graph/postgres_hash/mod.rs b/pgx-utils/src/sql_entity_graph/postgres_hash/mod.rs index bc02cfbea..a41943e1f 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_hash/mod.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_hash/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod entity; use proc_macro2::{Span, TokenStream as TokenStream2}; diff --git a/pgx-utils/src/sql_entity_graph/postgres_ord/entity.rs b/pgx-utils/src/sql_entity_graph/postgres_ord/entity.rs index d81310736..857e8bf2e 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_ord/entity.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_ord/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{ pgx_sql::PgxSql, to_sql::{entity::ToSqlConfigEntity, ToSql}, diff --git a/pgx-utils/src/sql_entity_graph/postgres_ord/mod.rs b/pgx-utils/src/sql_entity_graph/postgres_ord/mod.rs index e5b00ad95..1dc21292a 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_ord/mod.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_ord/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod entity; use proc_macro2::{Span, TokenStream as TokenStream2}; diff --git a/pgx-utils/src/sql_entity_graph/postgres_type/entity.rs b/pgx-utils/src/sql_entity_graph/postgres_type/entity.rs index 2ff831305..a05218518 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_type/entity.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_type/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{ mapping::RustSqlMapping, pgx_sql::PgxSql, diff --git a/pgx-utils/src/sql_entity_graph/postgres_type/mod.rs b/pgx-utils/src/sql_entity_graph/postgres_type/mod.rs index 9d7be6c08..07a99fdb6 100644 --- a/pgx-utils/src/sql_entity_graph/postgres_type/mod.rs +++ b/pgx-utils/src/sql_entity_graph/postgres_type/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod entity; use proc_macro2::{Ident, Span, TokenStream as TokenStream2}; diff --git a/pgx-utils/src/sql_entity_graph/schema/entity.rs b/pgx-utils/src/sql_entity_graph/schema/entity.rs index 890ba3ef7..0488ef0a3 100644 --- a/pgx-utils/src/sql_entity_graph/schema/entity.rs +++ b/pgx-utils/src/sql_entity_graph/schema/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{pgx_sql::PgxSql, to_sql::ToSql, SqlGraphEntity, SqlGraphIdentifier}; use std::cmp::Ordering; diff --git a/pgx-utils/src/sql_entity_graph/schema/mod.rs b/pgx-utils/src/sql_entity_graph/schema/mod.rs index a982ecd05..d48fcdc43 100644 --- a/pgx-utils/src/sql_entity_graph/schema/mod.rs +++ b/pgx-utils/src/sql_entity_graph/schema/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod entity; use proc_macro2::{Span, TokenStream as TokenStream2}; diff --git a/pgx-utils/src/sql_entity_graph/to_sql/entity.rs b/pgx-utils/src/sql_entity_graph/to_sql/entity.rs index 9fbe6e66d..385a7f2b3 100644 --- a/pgx-utils/src/sql_entity_graph/to_sql/entity.rs +++ b/pgx-utils/src/sql_entity_graph/to_sql/entity.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::sql_entity_graph::{pgx_sql::PgxSql, to_sql::ToSqlFn, SqlGraphEntity}; /// Represents configuration options for tuning the SQL generator. diff --git a/pgx-utils/src/sql_entity_graph/to_sql/mod.rs b/pgx-utils/src/sql_entity_graph/to_sql/mod.rs index d49b27aca..97e994d54 100644 --- a/pgx-utils/src/sql_entity_graph/to_sql/mod.rs +++ b/pgx-utils/src/sql_entity_graph/to_sql/mod.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ pub mod entity; use std::hash::Hash; diff --git a/pgx/src/aggregate.rs b/pgx/src/aggregate.rs index ae35fc305..e63111b2e 100644 --- a/pgx/src/aggregate.rs +++ b/pgx/src/aggregate.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ /*! [Aggregate](https://www.postgresql.org/docs/current/xaggr.html) support. diff --git a/pgx/src/atomics.rs b/pgx/src/atomics.rs index d8213ef57..d2cc0c0b9 100644 --- a/pgx/src/atomics.rs +++ b/pgx/src/atomics.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use once_cell::sync::OnceCell; pub struct PgAtomic { diff --git a/pgx/src/bgworkers.rs b/pgx/src/bgworkers.rs index 121b13455..b4ca78710 100644 --- a/pgx/src/bgworkers.rs +++ b/pgx/src/bgworkers.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Safely create Postgres Background Workers, including with full SPI support //! diff --git a/pgx/src/callbacks.rs b/pgx/src/callbacks.rs index 453582e62..64866ff53 100644 --- a/pgx/src/callbacks.rs +++ b/pgx/src/callbacks.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Provides safe wrappers around Postgres' "Transaction" and "Sub Transaction" hook system diff --git a/pgx/src/datum/anyarray.rs b/pgx/src/datum/anyarray.rs index 8abe5d1cf..12806bb1d 100644 --- a/pgx/src/datum/anyarray.rs +++ b/pgx/src/datum/anyarray.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, FromDatum, IntoDatum}; diff --git a/pgx/src/datum/anyelement.rs b/pgx/src/datum/anyelement.rs index 48b91f52a..3e3cc4fc7 100644 --- a/pgx/src/datum/anyelement.rs +++ b/pgx/src/datum/anyelement.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, FromDatum, IntoDatum}; diff --git a/pgx/src/datum/array.rs b/pgx/src/datum/array.rs index 5316292a7..16525f9a9 100644 --- a/pgx/src/datum/array.rs +++ b/pgx/src/datum/array.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, void_mut_ptr, FromDatum, IntoDatum, PgMemoryContexts}; use serde::Serializer; diff --git a/pgx/src/datum/date.rs b/pgx/src/datum/date.rs index c3b3a489f..08983acef 100644 --- a/pgx/src/datum/date.rs +++ b/pgx/src/datum/date.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, FromDatum, IntoDatum}; use std::ops::{Deref, DerefMut}; diff --git a/pgx/src/datum/from.rs b/pgx/src/datum/from.rs index 678fefa88..6b6f02e4f 100644 --- a/pgx/src/datum/from.rs +++ b/pgx/src/datum/from.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! for converting a pg_sys::Datum and a corresponding "is_null" bool into a typed Option diff --git a/pgx/src/datum/geo.rs b/pgx/src/datum/geo.rs index 11068a480..f17842056 100644 --- a/pgx/src/datum/geo.rs +++ b/pgx/src/datum/geo.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{direct_function_call_as_datum, pg_sys, FromDatum, IntoDatum}; diff --git a/pgx/src/datum/inet.rs b/pgx/src/datum/inet.rs index 9c00f959f..7247c5012 100644 --- a/pgx/src/datum/inet.rs +++ b/pgx/src/datum/inet.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ direct_function_call, direct_function_call_as_datum, pg_sys, pg_try, void_mut_ptr, FromDatum, diff --git a/pgx/src/datum/internal.rs b/pgx/src/datum/internal.rs index d3962dbc9..4eacfe860 100644 --- a/pgx/src/datum/internal.rs +++ b/pgx/src/datum/internal.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, FromDatum, IntoDatum, PgMemoryContexts}; diff --git a/pgx/src/datum/into.rs b/pgx/src/datum/into.rs index 5de216861..bc5c3d21d 100644 --- a/pgx/src/datum/into.rs +++ b/pgx/src/datum/into.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! for converting primitive types into Datums //! diff --git a/pgx/src/datum/item_pointer_data.rs b/pgx/src/datum/item_pointer_data.rs index 3f70cd13f..e902f48ae 100644 --- a/pgx/src/datum/item_pointer_data.rs +++ b/pgx/src/datum/item_pointer_data.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ item_pointer_get_both, item_pointer_set_all, pg_sys, FromDatum, IntoDatum, PgMemoryContexts, diff --git a/pgx/src/datum/json.rs b/pgx/src/datum/json.rs index d2ca2ec94..70cae4d1c 100644 --- a/pgx/src/datum/json.rs +++ b/pgx/src/datum/json.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ direct_function_call, direct_function_call_as_datum, pg_sys, vardata_any, varsize_any_exhdr, diff --git a/pgx/src/datum/mod.rs b/pgx/src/datum/mod.rs index ee529b107..16170398f 100644 --- a/pgx/src/datum/mod.rs +++ b/pgx/src/datum/mod.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Handing for easily converting Postgres Datum types into their corresponding Rust types //! and converting Rust types into their corresponding Postgres types diff --git a/pgx/src/datum/numeric.rs b/pgx/src/datum/numeric.rs index cd3eda936..4ecec5ae9 100644 --- a/pgx/src/datum/numeric.rs +++ b/pgx/src/datum/numeric.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{ direct_function_call, direct_function_call_as_datum, pg_sys, void_mut_ptr, FromDatum, IntoDatum, diff --git a/pgx/src/datum/time.rs b/pgx/src/datum/time.rs index d0c7f7ead..72e37af99 100644 --- a/pgx/src/datum/time.rs +++ b/pgx/src/datum/time.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, FromDatum, IntoDatum}; use std::ops::{Deref, DerefMut}; diff --git a/pgx/src/datum/time_stamp.rs b/pgx/src/datum/time_stamp.rs index a21a33ac1..0a4bf2912 100644 --- a/pgx/src/datum/time_stamp.rs +++ b/pgx/src/datum/time_stamp.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::datum::time::USECS_PER_SEC; use crate::{direct_function_call_as_datum, pg_sys, FromDatum, IntoDatum, TimestampWithTimeZone}; diff --git a/pgx/src/datum/time_stamp_with_timezone.rs b/pgx/src/datum/time_stamp_with_timezone.rs index 551724a47..9dcd8fdeb 100644 --- a/pgx/src/datum/time_stamp_with_timezone.rs +++ b/pgx/src/datum/time_stamp_with_timezone.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::datum::time::USECS_PER_SEC; use crate::{direct_function_call_as_datum, pg_sys, FromDatum, IntoDatum}; diff --git a/pgx/src/datum/time_with_timezone.rs b/pgx/src/datum/time_with_timezone.rs index f2d20f123..012b76661 100644 --- a/pgx/src/datum/time_with_timezone.rs +++ b/pgx/src/datum/time_with_timezone.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::datum::time::Time; use crate::{pg_sys, FromDatum, IntoDatum, PgBox}; diff --git a/pgx/src/datum/tuples.rs b/pgx/src/datum/tuples.rs index 45b69c952..d0a719f33 100644 --- a/pgx/src/datum/tuples.rs +++ b/pgx/src/datum/tuples.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, FromDatum, IntoDatum}; diff --git a/pgx/src/datum/uuid.rs b/pgx/src/datum/uuid.rs index 553de290c..a0569213f 100644 --- a/pgx/src/datum/uuid.rs +++ b/pgx/src/datum/uuid.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::{pg_sys, FromDatum, IntoDatum, PgMemoryContexts}; use core::fmt::Write; use std::ops::{Deref, DerefMut}; diff --git a/pgx/src/datum/varlena.rs b/pgx/src/datum/varlena.rs index 1ffba265c..df3a6a2c2 100644 --- a/pgx/src/datum/varlena.rs +++ b/pgx/src/datum/varlena.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Wrapper for Postgres 'varlena' type, over Rust types of a fixed size (ie, `impl Copy`) use crate::pg_sys::{VARATT_SHORT_MAX, VARHDRSZ_SHORT}; use crate::{ diff --git a/pgx/src/enum_helper.rs b/pgx/src/enum_helper.rs index 6337af552..fb509e010 100644 --- a/pgx/src/enum_helper.rs +++ b/pgx/src/enum_helper.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Helper functions for working with Postgres `enum` types diff --git a/pgx/src/fcinfo.rs b/pgx/src/fcinfo.rs index 6a71d5834..1f693b101 100644 --- a/pgx/src/fcinfo.rs +++ b/pgx/src/fcinfo.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Helper macros and functions for creating Postgres UDFs. //! diff --git a/pgx/src/guc.rs b/pgx/src/guc.rs index 9dbbc5d93..6902c1117 100644 --- a/pgx/src/guc.rs +++ b/pgx/src/guc.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Provides a safe interface into Postgres' Configuration System (GUC) use crate::{pg_sys, PgMemoryContexts}; diff --git a/pgx/src/hooks.rs b/pgx/src/hooks.rs index 4bfa43913..5d735e6ad 100644 --- a/pgx/src/hooks.rs +++ b/pgx/src/hooks.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! A trait and registration system for hooking Postgres internal operations such as its planner and executor use crate::{pg_guard, pg_sys, void_mut_ptr, PgBox, PgList}; diff --git a/pgx/src/htup.rs b/pgx/src/htup.rs index 83182a0a7..c6648c9d4 100644 --- a/pgx/src/htup.rs +++ b/pgx/src/htup.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Utility functions for working with `pg_sys::HeapTuple` and `pg_sys::HeapTupleHeader` structs use crate::*; diff --git a/pgx/src/inoutfuncs.rs b/pgx/src/inoutfuncs.rs index ea050c63d..28cb3fb8a 100644 --- a/pgx/src/inoutfuncs.rs +++ b/pgx/src/inoutfuncs.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Helper trait for the `#[derive(PostgresType)]` proc macro for overriding custom Postgres type //! input/output functions. diff --git a/pgx/src/itemptr.rs b/pgx/src/itemptr.rs index 93c4829a0..3de1e5dc1 100644 --- a/pgx/src/itemptr.rs +++ b/pgx/src/itemptr.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Helper functions for working with Postgres `ItemPointerData` (`tid`) type diff --git a/pgx/src/lib.rs b/pgx/src/lib.rs index b8991cc3e..5894dd338 100644 --- a/pgx/src/lib.rs +++ b/pgx/src/lib.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! `pgx` is a framework for creating Postgres extensions in 100% Rust //! diff --git a/pgx/src/list.rs b/pgx/src/list.rs index 55dc59b6a..973c8405c 100644 --- a/pgx/src/list.rs +++ b/pgx/src/list.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! A safe wrapper around Postgres' internal `List` structure. //! diff --git a/pgx/src/log.rs b/pgx/src/log.rs index 3ce36b32f..49a8b87b3 100644 --- a/pgx/src/log.rs +++ b/pgx/src/log.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Access to Postgres' logging system diff --git a/pgx/src/lwlock.rs b/pgx/src/lwlock.rs index 1368650af..8fe622967 100644 --- a/pgx/src/lwlock.rs +++ b/pgx/src/lwlock.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::pg_sys; use core::ops::{Deref, DerefMut}; use once_cell::sync::OnceCell; diff --git a/pgx/src/memcxt.rs b/pgx/src/memcxt.rs index 047921987..0c5daea66 100644 --- a/pgx/src/memcxt.rs +++ b/pgx/src/memcxt.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! //! Provides interfacing into Postgres' `MemoryContext` system. diff --git a/pgx/src/misc.rs b/pgx/src/misc.rs index e88de5846..dd42f5d92 100644 --- a/pgx/src/misc.rs +++ b/pgx/src/misc.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use std::hash::{Hash, Hasher}; /// wrapper around `SeaHasher` from [Seahash](https://crates.io/crates/seahash) diff --git a/pgx/src/namespace.rs b/pgx/src/namespace.rs index f1ca6e142..c1f609f09 100644 --- a/pgx/src/namespace.rs +++ b/pgx/src/namespace.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! A helper struct for creating a Postgres `List` of `String`s to qualify an object name diff --git a/pgx/src/nodes.rs b/pgx/src/nodes.rs index 92faeaefc..4b63b0e93 100644 --- a/pgx/src/nodes.rs +++ b/pgx/src/nodes.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Helper functions and such for Postgres' various query tree `Node`s diff --git a/pgx/src/pgbox.rs b/pgx/src/pgbox.rs index 1efb8b3b4..e11bcbe8e 100644 --- a/pgx/src/pgbox.rs +++ b/pgx/src/pgbox.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ /// Similar to Rust's `Box` type, `PgBox` also represents heap-allocated memory. use crate::{pg_sys, PgMemoryContexts}; diff --git a/pgx/src/rel.rs b/pgx/src/rel.rs index 36ab22bd8..c376e1e3b 100644 --- a/pgx/src/rel.rs +++ b/pgx/src/rel.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Provides a safe wrapper around Postgres' `pg_sys::RelationData` struct use crate::{ diff --git a/pgx/src/shmem.rs b/pgx/src/shmem.rs index 47822fc58..3c0847f96 100644 --- a/pgx/src/shmem.rs +++ b/pgx/src/shmem.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::lwlock::*; use crate::{pg_sys, PgAtomic}; use uuid::Uuid; diff --git a/pgx/src/spi.rs b/pgx/src/spi.rs index c0cfee1cb..ce286d3d1 100644 --- a/pgx/src/spi.rs +++ b/pgx/src/spi.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Safe access to Postgres' *Server Programming Interface* (SPI). diff --git a/pgx/src/stringinfo.rs b/pgx/src/stringinfo.rs index 96b2d72bf..ed42c3ce6 100644 --- a/pgx/src/stringinfo.rs +++ b/pgx/src/stringinfo.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! A safe wrapper around Postgres `StringInfo` structure #![allow(dead_code, non_snake_case)] diff --git a/pgx/src/trigger_support.rs b/pgx/src/trigger_support.rs index 32f0bc8a5..9885c911d 100644 --- a/pgx/src/trigger_support.rs +++ b/pgx/src/trigger_support.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Helper functions for working with custom Rust trigger functions diff --git a/pgx/src/tupdesc.rs b/pgx/src/tupdesc.rs index 47c00868a..23cad51a1 100644 --- a/pgx/src/tupdesc.rs +++ b/pgx/src/tupdesc.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Provides a safe wrapper around Postgres' `pg_sys::TupleDescData` struct use crate::{pg_sys, void_mut_ptr, AllocatedByRust, FromDatum, PgBox, PgRelation}; diff --git a/pgx/src/varlena.rs b/pgx/src/varlena.rs index 573de94af..56aae6543 100644 --- a/pgx/src/varlena.rs +++ b/pgx/src/varlena.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Helper functions to work with Postgres `varlena *` structures diff --git a/pgx/src/wrappers.rs b/pgx/src/wrappers.rs index 3da7dd2ba..ec45a751c 100644 --- a/pgx/src/wrappers.rs +++ b/pgx/src/wrappers.rs @@ -1,3 +1,11 @@ +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ //! Provides safe wrapper functions around some of Postgres' useful functions. use crate::{direct_function_call, pg_sys, IntoDatum}; diff --git a/pgx/src/xid.rs b/pgx/src/xid.rs index 9396d46a4..2298f71f3 100644 --- a/pgx/src/xid.rs +++ b/pgx/src/xid.rs @@ -1,5 +1,11 @@ -// Copyright 2020 ZomboDB, LLC . All rights reserved. Use of this source code is -// governed by the MIT license that can be found in the LICENSE file. +/* +Portions Copyright 2019-2021 ZomboDB, LLC. +Portions Copyright 2021-2022 Technology Concepts & Design, Inc. + +All rights reserved. + +Use of this source code is governed by the MIT license that can be found in the LICENSE file. +*/ use crate::pg_sys; diff --git a/publish.sh b/publish.sh index 5fa75fde5..b86afeb71 100755 --- a/publish.sh +++ b/publish.sh @@ -1,4 +1,12 @@ #! /bin/sh +# Portions Copyright 2019-2021 ZomboDB, LLC. +# Portions Copyright 2021-2022 Technology Concepts & Design, Inc. +# +# +# All rights reserved. +# +# Use of this source code is governed by the MIT license that can be found in +# the LICENSE file. DIR=`pwd` set -x diff --git a/update-versions.sh b/update-versions.sh index 4b2f42b96..526a88cf6 100755 --- a/update-versions.sh +++ b/update-versions.sh @@ -1,4 +1,12 @@ #! /usr/bin/env bash +# Portions Copyright 2019-2021 ZomboDB, LLC. +# Portions Copyright 2021-2022 Technology Concepts & Design, Inc. +# +# +# All rights reserved. +# +# Use of this source code is governed by the MIT license that can be found in +# the LICENSE file. # requires: # * ripgrep diff --git a/upgrade-deps.sh b/upgrade-deps.sh index 1e6e42810..b80e298f2 100755 --- a/upgrade-deps.sh +++ b/upgrade-deps.sh @@ -1,4 +1,12 @@ #! /usr/bin/env bash +# Portions Copyright 2019-2021 ZomboDB, LLC. +# Portions Copyright 2021-2022 Technology Concepts & Design, Inc. +# +# +# All rights reserved. +# +# Use of this source code is governed by the MIT license that can be found in +# the LICENSE file. # requires: "cargo install cargo-edit" from https://github.com/killercup/cargo-edit cargo update