mirror of
https://github.com/brunopostle/ifcurl.git
synced 2026-07-12 02:08:13 +00:00
Implements ifcurl-i07. fetch_ifc_path() fetches the IFC file and writes it to ~/.cache/ifcurl/<url-hash>/<hexsha>/<basename>, returning the path alongside the is_stale flag. Content-addressed by commit hexsha, so the file is never rewritten once present. Works for both local and remote URLs. Underpins the connector and checkout layers (ifcurl-5oo). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
24 lines
1,010 B
Python
24 lines
1,010 B
Python
# IFC URL — resolve and render ifc:// URLs
|
|
# Copyright (C) 2026 Bruno Postle <bruno@postle.net>
|
|
# SPDX-License-Identifier: LGPL-3.0-or-later
|
|
#
|
|
# This file is part of IFC URL.
|
|
#
|
|
# IFC URL is free software: you can redistribute it and/or modify
|
|
# it under the terms of the GNU Lesser General Public License as published by
|
|
# the Free Software Foundation, either version 3 of the License, or
|
|
# (at your option) any later version.
|
|
#
|
|
# IFC URL is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU Lesser General Public License for more details.
|
|
#
|
|
# You should have received a copy of the GNU Lesser General Public License
|
|
# along with IFC URL. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
from ifcurl.git import fetch_ifc, fetch_ifc_bytes, fetch_ifc_path
|
|
from ifcurl.url import IfcUrl
|
|
|
|
__version__ = "0.0.0"
|
|
__all__ = ["IfcUrl", "fetch_ifc", "fetch_ifc_bytes", "fetch_ifc_path"]
|