mirror of
https://github.com/brunopostle/ifcurl.git
synced 2026-07-12 10:18:14 +00:00
Implements ifcurl-5oo. get_checkout() ensures the bare cache is current via fetch_ifc(), then clones it locally to <cache_dir>/checkout/ (no network), and places it at the resolved commit as a detached HEAD — forcing branch creation before any commit. Viewer artefact patterns (*.ifcview, *.rdbview, etc.) are appended to .git/info/exclude so they are locally ignored without touching the repo's own .gitignore. When a newer commit is requested, the checkout fetches from origin (the local bare cache) using the default refspec to avoid git's "refusing to fetch into checked-out branch" error. Unblocks the JSON-RPC connector (ifcurl-242). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
26 lines
1.1 KiB
Python
26 lines
1.1 KiB
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.checkout import get_checkout
|
|
from ifcurl.discover import find_local_repos
|
|
from ifcurl.git import fetch_ifc, fetch_ifc_bytes, fetch_ifc_path, get_genesis_commit
|
|
from ifcurl.url import IfcUrl
|
|
|
|
__version__ = "0.0.0"
|
|
__all__ = ["IfcUrl", "fetch_ifc", "fetch_ifc_bytes", "fetch_ifc_path", "get_genesis_commit", "find_local_repos", "get_checkout"]
|