import os

import pandas as pd
import geopandas as gpd
from pathlib import Path

folder = Path("/home/ftp/pub/data/G18/merged_maps")
shapefiles = folder.glob("*.shp")
gdf = pandas.concat([
    geopandas.read_file(shp)
    for shp in shapefiles
]).pipe(geopandas.GeoDataFrame)
gdf.to_file(folder / 'compiled.shp')
